Timothy:

As you seem to have already found out, most browsers tend to ignore the
ACCEPT attribute.  You might try ACCEPT="application/vnd.ms-excel" since
that is the correct mime-type for Excel files but I still doubt that it
would work in most major browsers.

Your best bet, as has already been suggested, is to use JavaScript to scan
the value of the INPUT field (onChange) to check the last 4 characters of
the filename.  Just be sure to note the concerns mentioned in the other
emails.

--
Mosh Teitelbaum
evoch, LLC
Tel: (301) 942-5378
Fax: (301) 933-3651
Email: [EMAIL PROTECTED]
WWW: http://www.evoch.com/


> -----Original Message-----
> From: Claremont, Timothy [mailto:[EMAIL PROTECTED]
> Sent: Monday, July 07, 2003 12:09 PM
> To: CF-Talk
> Subject: CFFILE Input Filter?
>
>
> Can anyone tell me if I can filter the input on a CFFILE input screen? I
> know I can filter what the server will accept, and throw an error, but I
> would like to prevent users from even attempting to upload anything but
> an Excel file if possible.
>
> In other words, when the user clicks the button to browse their own
> computer for the file that they want to upload, I want it to only
> display the .XLS files, instead of ALL files.
>
> Apparently the following code does not achieve this:
>
> <input type="file" name="filetoupload" size="75"
> accept="application/msexcel">
>
> Thanks in advance!
>
>
> **********************************************************************
> This email and any files transmitted with it are confidential and
> intended solely for the use of the individual or entity to whom they
> are addressed. If you have received this email in error please delete.
> it.
> Thank you,
> ViaHealth
>
> **********************************************************************
>
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq

Signup for the Fusion Authority news alert and keep up with the latest news in 
ColdFusion and related topics. 
http://www.fusionauthority.com/signup.cfm

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to