Online Chat
 Call Us: 
1-877-744-1221
Browse Submit a Ticket
 
Advanced Search
Tools
Rss Categories

How can I allow only certain file extensions for user file uploading?

Author: Eileen Wilde Reference Number: AA-00186 Views: 8789 Last Updated: 08/10/2009 11:32 AM 0 Rating/ Voters

Set the allowed file extensions for user file uploads in the file_filter_fields.

Syntax:

allowed_files = ext

or

allowed_files = ext1|ext2|ext3

Example:

In your form:


<input type="file" name="attach">

Config file:

allowed_files = gif|bmp|png
file_filter_fields = attach (Picture)
Result:   
Only *.gif, *.bmp, *.png files will be allowed for during upload.