Re: File Upload Re: FWD HTML DOM

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: File Upload Re: FWD HTML DOM

Arun Ranganathan

Erez, public-webapi, et al.,

I'm responsible for cleaning up the FileUpload spec.[1] which has been
lying around dormant for some time.  Erez, I saw email from you dated
Feb 12 [2] asking about this very type of specification.

Sounds like what you want is a hook to determine what to do with files
chosen by <input type = "file" />  The existing work[1] provides a
framework for a bit more than that.

Open questions that I'd like to see discussion on the listserv to help
me think about this and take this to a better place (!) are:

1. Interfaces suggested are File, FileList, FilesSelectionEvent, and
FileDialog, with the exception that could thrown being FileException.  I
can see the FilesSelectionEvent satisfying Erez's ask for some sort of
event trigger following <input type="file"/> (which could set off
instantiation of FileDialog or anything else).   But in general, is this
overkill, underkill, just right?  Should the situations that spawn
FileDialog be extremely limited?  Is there *really* merit in being able
to get* the file as a Base64 blob in script (one of File's methods)?

2. Security.  Assuming we don't chuck out some of the above interfaces,
what should we do for security robustness on some of these?  Suggestions
welcome.

I guess the ask is: what is the safest and most practical thing that can
be done to meet the ask from the developer community?  Your responses
will help get me working on a strawperson proposal :)

-- A*

[1]
http://dev.w3.org/cvsweb/~checkout~/2006/webapi/FileUpload/publish/FileUpload.html

[2] http://lists.w3.org/Archives/Public/public-webapi/2007Feb/0058
--
Arun Ranganathan, System Architect
AOL LLC
http://www.arunranga.com/

Reply | Threaded
Open this post in threaded view
|

Re: File Upload Re: FWD HTML DOM

Anne van Kesteren-2

On Mon, 26 Feb 2007 23:58:16 +0100, Arun Ranganathan <[hidden email]>  
wrote:
> Sounds like what you want is a hook to determine what to do with files  
> chosen by <input type = "file" />  The existing work provides a  
> framework for a bit more than that.

There's some discussion about this API here:

   https://bugzilla.mozilla.org/show_bug.cgi?id=371432


The summary would be that the new event is dropped. HTMLInputElement would  
get a new member called fileList which either returns null or FileList  
depending on whether files have been selected or not. Changes to  
HTMLInputElement would be signaled through the 'change' event and possibly  
the 'input' event. (Which already dispatch on it.)


--
Anne van Kesteren
<http://annevankesteren.nl/>
<http://www.opera.com/>