Chris,

I'm alread using the ACCEPT attribute in the CFFILE tag. However, if you try 
and upload a non-GIF file to the server, you get a standard CF error page.

What I was hoping to do was to trap the problem and specifically know that 
it was a bad file type as opposed to another error and re-direct the user 
and alert them to the problem. Simply using catch type="Any" doesn't really 
give me enough info to do this.


----Original Message Follows----
From: "Christopher Olive" <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
To: CF-Talk <[EMAIL PROTECTED]>
Subject: RE: Advanced CFCATCH Exception Types
Date: Wed, 6 Feb 2002 15:46:24 -0500

perhaps i'm oversimplifying, but can't you use the

ACCEPT="mime_type/file_type"

attribute of CFFILE in the upload?

christopher olive, cto, vp of web development
atnet solutions, inc.
410.931.4092
http://www.atnetsolutions.com


-----Original Message-----
From: Dave Carabetta [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, February 06, 2002 3:13 PM
To: CF-Talk
Subject: Advanced CFCATCH Exception Types


I would like to trap a CFFILE error using CFTRY/CFCATCH if the user
submits
a bad file type. I only want to allow them to upload .gif files.

I can use the CFCATCH TYPE="Any" to trap it, but I was hoping that I
could
trap specifically for a bad file type.

I noticed that there are a whole slew of "advanced" exception types
starting
with COM.* listed in the documentation, but I can't find one for a bad
file
type.

Can one of those advanced types or a regular type be used other than
"Any"?

Thanks,
Dave.


_________________________________________________________________
Join the world's largest e-mail service with MSN Hotmail.
http://www.hotmail.com


______________________________________________________________________
Dedicated Windows 2000 Server
  PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER
  Instant Activation · $99/Month · Free Setup
  http://www.pennyhost.com/redirect.cfm?adcode=coldfusiona
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to