Returns an array of structs by default. Each struct contains template name, line number, and function name (if applicable). This is a snapshot of all function calls or invocations.
callStackGet()
→ returns any
array
0
0
This example the factorial of a number is computed.
<!--- callfact.cfm --->
<cftry>
<cfinclude template="fact.cfm">
<cfcatch type="any">
<cfoutput>
#cfcatch.message#
<br>#cfcatch.detail#<br>
</cfoutput>
</cfcatch>
</cftry>
This example the factorial of a number is computed.
<!--- fact.cfm --->
<cfscript>
numeric function factorial(n) {
if (n == 1) {
writeDump(callStackGet());
writeOutput('<br>');
return 1;
}
else {
writeDump(callStackGet());
writeOutput('<br>');
return n * factorial(n-1);
}
}
factorial(5);
</cfscript>
Signup for cfbreak
to stay updated on the latest news from the ColdFusion / CFML community. One email, every friday.