"RWK" <me@nowhere.com> wrote in message
news:b4******************@newssvr31.news.prodigy.c om...
I'm trying to figure out how to verify that the file trying to be
uploaded
exists. On my page if I type in the name of a file that doesn't exist
it
get's uploaded as a file with 0 bytes.
When using Yahoo mail when I type in a non-existent file and try to
upload
it will come back and tell me "Invalid File" but I can't figure out
how they
are doing it.
I just ran a small test. It's pretty obvious that when you click Attach
Files the file is actually uploaded (and most likely tagged with a
message id so Yahoo! knows which message it "belongs to"). So the server
is detecting that the file is 0 bytes and complaining.
This was verified by -touch-ing a file and attempting to attach it, I
got the same "Invalid File" message.
In other words, the detection is not happening on the client (nor can it
in a cross-platform, cross-browser way).
--
Grant Wagner <gw*****@agricoreunited.com>
comp.lang.javascript FAQ -
http://jibbering.com/faq