This section discusses the advanced topics of dynamic expressions, dynamic evaluation, and dynamic variable naming. Many ColdFusion programmers never encounter or need to use dynamic expressions. However, dynamic variable naming is important in situations where the variable names are not known in advance, such as in shopping cart applications.
This section also discusses the use of the IIf
function, which is most often used without dynamic expressions. This function dynamically evaluates its arguments, and you must often use the DE
function to prevent the evaluation. For more information on using the IIF
function, see Using the IIF function.
Note: This section uses several tools and techniques that are documented in later chapters. If you are unfamiliar with using ColdFusion forms, structures, and arrays, you should learn about these tools before reading this section.
This section describes the following topics: