|
Posted by Jonathan N. Little on 10/02/05 18:28
Randy Webb wrote:
<snip>
>> Well yes if the client has JavaScript disabled! ;-)
>
>
> It wouldn't work even with Javascript enabled.
>
Firstly, I am not saying the OP should do this, I think it is a bad
idea. However are you saying that you cannot build a file list of local
files using JavaScript and the file input? Because this simple codes
builds such a list....
<code>
<form>
<textarea name='abc' rows=30 cols=50></textarea>
<input type=file onchange="this.form.abc.value+=';' + this.value; return
true;">
</form>
</code>
>> I would think you would need more JavaScript to enter list/array into
>> a form input that would be passed to some server-side script to do the
>> actual uploading...
>
>
> If what you are describing is possible in javascript, then anybody could
> simply set the value of a hidden field to whatever file they wanted off
> your PC and upload it automatically. That is not allowed (and what you
> are describing) for that very reason. File inputs are very limited in
> javascript context for a reason - security.
>
Now JavaScript cannot be used to upload files, but the list sent to a
server-side script could use the list a as a queue, right? Am I
mistaken? Again, I do not think this is a very good idea...purely
curiosity and a 'what if' question.
--
Take care,
Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
[Back to original message]
|