Put the variable in quotes. <CFIF IsDefined("var")>
----- Original Message -----
From: "Paul Johnston" <[EMAIL PROTECTED]>
To: "Cf-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, August 24, 2000 9:57 AM
Subject: IsDefined() problems
> Just a quickie.
>
> I have taken to coding in this way (when I think var may be undefined):
>
> <cfparam name="var" default="">
> <cfif var eq "">
> ... do something ...
> </cfif>
>
> instead of:
>
> <cfif IsDefined(var)>
> ... do something ...
> </cfif>
>
> Does anyone else have trouble with IsDefined() or is it just me using it
> wrong?
>
> Paul
>
>
> --------------------------------------------------------------------------
----
> Archives: http://www.mail-archive.com/[email protected]/
> To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.
>
------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.