htmlinputfile - accept

G

Guest

Hi
I saw an example that we can limit file selection type to image only with
accept="image/*", but how do I limit the selection to only
1. comma separated file (.csv)
2. text file (.txt)

please?!

TIA

--
 
G

Guest

Is this a lie or what, even the "image/*" would not work?! Has anyone ever
get this working?
 
G

Guest

Any chance for these two types though
1. comma separated file (.csv)
2. text file (.txt)
TIA

Martin said:
just set the selection type to image AND check in ur code 2
 
M

Mythran

Any chance for these two types though
1. comma separated file (.csv)
2. text file (.txt)
TIA

You could try:

accept="text/csv,text/plain"

This should allow only csv and plain-text files to be uploaded (IE: No
binary files)....

HTH,

Mythran
 
B

bugmenot

Ever get this to work? I'm having the same issue.
image/* doesn't seem to do anything.
And I don't understand what is meant by "just set the selection type
to image AND check in ur code "
 

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,755
Messages
2,569,536
Members
45,014
Latest member
BiancaFix3

Latest Threads

Top