D
darrel
I have an input type="file" field that I am using to accept a file upload.
This works, but I'm having problems with the filename property.
In firefox, this:
MyInputField.postedfile.filename
returns the filename...and just the filename. Which is what I want.
In IE, however, this returns the ENTIRE local user's system path to the file
+ the filename. Which, is pretty useless for most applications. (Actually,
it seems like a security issue.)
Is there a workaround for this short of parsing the entire filepath looking
for backslashes? I can certainly do that, but maybe there is a better way to
grab just the filename when the end-user is using IE.
-Darrel
This works, but I'm having problems with the filename property.
In firefox, this:
MyInputField.postedfile.filename
returns the filename...and just the filename. Which is what I want.
In IE, however, this returns the ENTIRE local user's system path to the file
+ the filename. Which, is pretty useless for most applications. (Actually,
it seems like a security issue.)
Is there a workaround for this short of parsing the entire filepath looking
for backslashes? I can certainly do that, but maybe there is a better way to
grab just the filename when the end-user is using IE.
-Darrel