Re: Fwd: File Upload Status ?

Garrett Smith wrote:
 > Firefox 3:
 >   File
 >     fileName
 >     fileSize
 >
 >     getAsBinary()
 >     getAsDataURL()
 >     getAsText()
 >
 > Working Draft:
 >   File
 >     readonly attribute DOMString      fileName;

Exists

 >     readonly attribute DOMString      mediaType;

Sounds like your usecase is a good one, please file a bug to get this 
implemented in firefox.

 >     readonly attribute unsigned long  fileSize;

exists

 >     DOMString          getDataAsString()
 >                                         raises(FileException);

same as getAsText

 >     DOMString          getDataAsBase64()
 >                                         raises(FileException);

What is the usecase for this? Seems like getAsDataURL is what you 
usually want.

 >     DOMString          getDataAsHexBinary()

What is the use for this? Seems like getAsBinary is a better solution 
for accessing the raw data.

 > (regarding FileDialog)
 >> I'm not sure if this is a super desirable feature from a security 
point of
 >> view. Technically speaking a site could take a users browser hostage 
unless
 >> the user agrees to give up a sensitive file:
 >>
 >
 > Thanks for pointing that out. That's pretty nasty. It's a good case
 > for removing FileDialog. What is the use case for FileDialog that
 > can't be fulfilled by the browse button?

Not depending on HTML i suspect. But that's a guess.

In general I definitely support having the File object specified. Not 
sure how big of a fan I am of the other parts of the current spec 
though. But I don't have very strong feelings either way as of yet.

/ Jonas

Received on Friday, 8 August 2008 21:30:33 UTC