Sean Corfield wrote:
On Sat, 4 Dec 2004 16:38:34 +1100, Steve Onnis <[EMAIL PROTECTED]> wrote:

<cfset result = iif(isDefined("myVar"),"'the value myVar is ' & myVar","")>

So the value of the first argument is 'the value myVar is ' & myVar


Er, and then call evaluate() on it? Yuk! That's even worse...

Actually you don't have to do that (when I sent my response I tried it out and it worked fine), although it must be doing something similar inside iif - prolly no worse than evaluating a string with ## mark interpolation. Personally I'd like to see the ternary


condition ? option 1 : option 2

operator in CF, particularly as I use it often in Actionscript and it's just another thing to fall over switching between the two.

Cheers,
Robin

http://www.rocketboots.com.au

---
You are currently subscribed to cfaussie as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]
Aussie Macromedia Developers: http://lists.daemon.com.au/

Reply via email to