Description

Runs when you execute the tag cfabort.

Note: If showError attribute is specified in cfabort, onError method is executed instead of OnAbort.

Note: When using cfabort, cflocation, or cfcontent tags, the OnAbort method is invoked instead on OnRequestEnd.

Returns

Nothing

Syntax

<cffunction name="onAbort" returnType="boolean">
<cfargument type="string" name="targetPage" required=true/>
...
<cfreturn BooleanValue />
</cffunction>

Parameters

Parameter

Description

targetPage

The path from the web root to the requested CFML page.

Example

Application.cfc

<cfcomponent>
<cffunction name="onAbort"
access="public"
returntype="void"
hint="Hanldes Aborted request">

<cfargument type="String"
name="targetPage"
required=true/>
<cfoutput> Target Page: #targetPage#</cfoutput>
<!--- do stuff --->
</cffunction>
</cfcomponent>

Test.cfm

<cfabort>

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License  Twitter™ and Facebook posts are not covered under the terms of Creative Commons.

Legal Notices   |   Online Privacy Policy