<div class="gmail_quote">On Mon, Dec 14, 2009 at 11:39 AM, Jonas Sicking <span dir="ltr"><jonas@sicking.cc></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

<div><div></div><div class="h5">On Mon, Dec 14, 2009 at 10:33 AM, Ojan Vafai <<a href="mailto:ojan@chromium.org">ojan@chromium.org</a>> wrote:<br>
> On Sun, Dec 13, 2009 at 7:47 AM, Jonas Sicking <jonas@sicking.cc> wrote:<br>>> On Sun, Dec 13, 2009 at 5:36 AM, TAMURA, Kent <<a href="mailto:tkent@chromium.org">tkent@chromium.org</a>> wrote:<br>
>> > What should happen to selected files in a case that a user selects<br>
>> > multiple<br>
>> > files for <input type=file multiple> and then a script code removes the<br>
>> > multiple attribute from the input element?<br>
>> >  - nothing, no change to the selected files and they will be submitted,<br>
>> >  - cleared, or<br>
>> >  - a single file remains<br>
>><br>
>> I ran into the same question when developing this for firefox. I don't<br>
>> really care what happens either way since I don't see a use case for<br>
>> removing the multiple attribute.<br>
>><br>
>> What I ended up doing was to do your first option above.<br>
><br>
> This should be an invalid thing to do. Can we throw an exception in addition<br>
> to leaving the list of files untouched?<br>
<br>
</div></div>I would prefer not to throw an exception. Making removeAttribute throw<br>
an exception seems wrong since the attribute *is* in fact removed, and<br>
making foo.multiple=false throw would mean that it would behave<br>
differently from all other "mapped" IDL attributes.<br>
<br>
I'd really prefer to keep things simple here as I doubt that this is<br>
something that anyone will ever do. Much less depend on a particular<br>
behavior.<br>
<br>
You're off course free to put a warning in a developer console or<br>
something like that though.</blockquote><div><br></div><div>I buy that. A warning seems appropriate. I'm sure *someone* will do this someday, but it's probably rare enough that it's not worth putting effort into.</div>

<div><br></div><div>Ojan</div></div><br>