[thelist] Dw MX concensus

Raymond Camden jedimaster at macromedia.com
Thu May 9 15:43:01 CDT 2002


>
> oh, and the both of you owe tips.  now pay up.

It's been too long anyway...

<tip type="ColdFusion">

	As .jeff just stated, Variables is now a real structure, so this
means there is one less reason to use evaluate:

	<cfset x = 1>
	<cfset want = "x">
	<cfoutput>The value of #want# is #variables[want]#.

</tip>

<tip type="ColdFusion">

	In ColdFusion 5 (and earlier), you could write code like this
and get away with it:

	<cfset x.y = 1>
	<cfset x.a = 2>

	However, in this case, x is NOT a true struct because you never
ran the structNew() function. Instead, yuo had two variables named "x.y"
and "x.a". In CFMX, we will auto-create the structure for you. However,
I still suggest you use structNew().

	p.s. If you do want to auto create an complex struct on the fly,
you can use structGet - this works in cf5 as well.

</tip>


=======================================================================
Raymond Camden, ColdFusion Jedi Master for Macromedia

Email    : jedimaster at macromedia.com
Yahoo IM : morpheus

"My ally is the Force, and a powerful ally it is." - Yoda




More information about the thelist mailing list