$upload->set_acceptable_types('image'); // comma separated string, or array
How do I get this to also except plain text file. Using an upload form for images and would like to let users upload small text file.
upload form
Moderator: General Moderators
- shiznatix
- DevNet Master
- Posts: 2745
- Joined: Tue Dec 28, 2004 5:57 pm
- Location: Tallinn, Estonia
- Contact:
well we would have to see this class that you are dealing with.
beware, there is no real way of telling if it is a txt file or not for sure. the only way that comes to mind is strpos for .txt but I can still have a file bad_virus.exe.txt and it would still run as a exe and thus be a very big security problem.
beware, there is no real way of telling if it is a txt file or not for sure. the only way that comes to mind is strpos for .txt but I can still have a file bad_virus.exe.txt and it would still run as a exe and thus be a very big security problem.
OK sounds logical .
What I am trying to do is actually add a comments section to my multi upload form.
To be honest I am new to PHP and get my scripts from online sources "free or purchased"
I use this form for only select few to upload pics and highlights of a game.
Any ideas will be greatly appreciated.
Thanks !
What I am trying to do is actually add a comments section to my multi upload form.
To be honest I am new to PHP and get my scripts from online sources "free or purchased"
I use this form for only select few to upload pics and highlights of a game.
Any ideas will be greatly appreciated.
Thanks !