How to filter file types when using the HTMLInputFile control...

A

Asela Gunawardena

On my Web Servers, I don't want to allow visitors to upload executables.
There are many types of files that i want to ignore (for instance: exe,dll,
bat, cmd .etc). I have an ASPX page with an HTMLInputFile control which
uploads the files. Is it possible to set a filter when the user clicks the
Browse button so that the
file selection dialog only displays valid formats specified.

thankx in advance

Asela Gunawardena.
 
N

Nathan Sokalski

Try using the Accept property of the HtmlInputFile control. I have never
used it, but it sounds like what you are looking for. You can probably find
the details in the Help files. Good Luck!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,576
Members
45,054
Latest member
LucyCarper

Latest Threads

Top