>       I am trying to work on making an automated error page.
> Thing is stupid cferror doesn't let you use any tags in your
> error page. So what I have to do is
> mailto:[EMAIL PROTECTED]?subject=error&body=errortext
> only thing is once it hits some text in there it craps out
> on the body part. Has anyone done something like this?

CFERROR isn't "stupid" for not letting you use any tags. Think about it for
a minute. What if CFERROR let you use tags? If you used the same tag which
caused the error in the first place, what would happen?

There are several approaches for error handling in CF, and you're free to
use some or all of them.

1. The CFERROR tag.
There are several ways that CFERROR can be used. The most common way is to
use TYPE="REQUEST", and send the user to a harmless error message. You can
extend this approach using JavaScript; for more information, take a look at
this:

http://alive.allaire.com/Bagdhad/CatalogCourseDetail.cfm?CourseID=36

In addition, CFERROR now has two new ways it can be used: TYPE="EXCEPTION"
and TYPE="MONITOR". These are both new to 4.5. The exception type looks
interesting; you can use tags in the error page used by that type.

2. CFTRY/CFCATCH
If you want to respond to a specific problem condition within a specific
block of code, this is the best approach. You can use any CFML code you want
inside your CFCATCH block.

3. The site-wide error handler (new to CF 4.5)
You can specify a default page for any errors.

You can use all of these together; you can use a site-wide error handler,
override that with a CFERROR tag in a specific application, and override
that with an exception handler.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
voice: (202) 797-5496
fax: (202) 797-5444

------------------------------------------------------------------------------
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to