Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.
-
Xuan Mai #1
Nesting functions in CFC's
I'm trying to move the contents of my Application.cfm and OnRequestEnd.cfm to a
new Application.cfc. Everything works, except for the UDF's. I need to have
them called on most every page, so I put them in the onRequestStart function
like so:
I end up with this error:
Invalid CFML construct found on line 167 at column 35.
The function GetScale is illegally nested inside of another function
definition onRequestStart, which is located at line 166, column 27.
If I put it outside all the other functions, it won't get called. Where am I
supposed to put the UDF's?
<cffunction name="onRequestStart">
<cffunction name="GetScale" returntype="numeric">
<cfargument name="val" required="yes" type="numeric" default="">
function GetScale(val) {
// function calls here
}
</cffunction>
</cffunction>
Xuan Mai Guest
-
Does BlazeDS can work with CFC's ???
Hi all i'm really confused about the BlazeDS release is this remoting service aimed for Java Developers only or can you invoke CFC's functions,... -
Pathing with CFC's
I'm reading Ben Forta's (EXCELLENT) book, but he (as well as every site I've Google'd so far) does not give information about the question I'm going... -
Is Application.cfm included in CFC's
See title. -
Calling Cfc's
I am developing two applications on the same server that will have a lot of overlapping functionality. Hence, I would like to share cfcs between the... -
When to use getters/setters with CFC's
I'm a bit confused as to when it is good practice to use getter/setter methods in CFC's and when to use the THIS scope to make the properties...



Reply With Quote

