Stas,
Thanks. Also, I read in Forta's book that any code after <CFLOCATION>
would be ignored, but he didn't say whether that was true if it was
included as part of a conditional statement.
--John
stas wrote:
>
> An easy solution would be to use <cfparam> to initialize variables to a default
>value if they don't exist.
> You could use something like this:
>
> <cfparam name = "myvar" default = "">
>
> then do a check:
>
> <cfif not(len(myvar))>
> <cflocation url="myurl.cfm">
> </cfif>
>
> I think it's a little cleaner than using IsDefined and then checking if the var is
>empty.
>
> Original message from: John Allred
> >I have several templates that require an ID variable to be passed to
> >them. When the templates load, they run a query "WHERE (COUNTY_NO =
> >'#ID#')" -- ID is a CGI variable.
>
> ------------------------------------------------------------------------------
> Archives: http://www.eGroups.com/list/cf-talk
> 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.
--
John Allred / Jackson, Mississippi
Webmaster, Mississippi Counties
http://www.mscounties.com/
------------------------------------------------------------------------------
Archives: http://www.eGroups.com/list/cf-talk
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.