Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Filter the dialog box..?

Status
Not open for further replies.

adamsoderqvist

Programmer
Sep 8, 2001
136
SE
Hi everyone
Have a browser dialog box, using:

<input type=file name=file1>

Now, I want to filetr it so that only pictures are avaliable to pick. I've tried this:

<input type=file name=file1 style="FILTER: *.gif; *.jpg;">

but with no luck.

Any suggestions..?

/
 
i dont think that will work, a better way would be to check the value after the user selects the file.

if u still want to use filters think u might be looking for the "Accept" attribute...

Known is handfull, Unknown is worldfull
 
To elaborate on vbkris's post, you might try this link for additional information on the accept attribute. Thanks, vbkris, for that information! I was previously unaware of that particular attribute. [thumbsup]

------------------------------------------------------------------------------------------------------------------------
If you don't have a sense of humor, you probably don't have any sense at all.
- Anonymous
 
no problemmo...

Known is handfull, Unknown is worldfull
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top