September 2007
Intermediate to advanced
600 pages
20h 21m
English
The functions defined thus far are simple ones, in that they accept no data and return a result. But many of the functions that you’ll create will need to accept data. For example, if you were creating a CFC function that returned movie details, you’d need to pass the desired movie ID to the function.
In CFC lingo, passed data are called arguments and the tag that is used to define arguments is the <cfargument> tag. If used, <cfargument> must be the very first code within a <cffunction>, and multiple <cfargument> tags may be used if needed.
Tip
You may sometimes see the word parameter used too. Parameters and arguments are one and the same.
The following code snippet demonstrates the use of <cfargument>:
<cfargument name="radius" ...
Read now
Unlock full access