Really? Was it not using that variable anywhere else in the tag?

... nevermind, just saw your snippet. :) Yea, didn't seem to have a
real reason for using it there...


> Hah. So, all I had to do was comment out the <cfset
> thistag.hasendtag =
> 1>and it worked.

> Thanks list.

> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf
> Of S.Isaac Dealey
> Sent: Thursday, January 15, 2004 3:54 PM
> To: [EMAIL PROTECTED]
> Subject: RE: ThisTag attribute

> It used to be a not all to uncommon practice to set the
> executionmode
> variable in a custom tag in order to resolve a tag which
> may or may
> not need an end tag but which must perform any behavior
> only in the
> end tag if it does have an end tag. Thistag can contain
> other stuff
> usually as a result of sub-tags using the <cfassociate> in
> which case
> what's in thistag may be largely custom and can have
> pretty much any
> name or shape. You can dump the thistag scope with cfdump
> also...

> But more on the issue you're having:

> Typically you'd have a structure kinda like this:

> <cfparam name="attributes.blah">

> <cfif not thistag.hasendtag>
>   <cfset thistag.executionmode = "end">
> </cfif>

> <cfif thistag.executionmode is "end">
>   ... do stuff here ...
> </cfif>

> So the way around this is of course to comment out the
> cfif with the
> set tag in it and instead use

> <cfif thistag.executionmode is "end" or not
> thistag.hasendtag>
>   ... do stuff here ...
> </cfif>

> Not entirely sure why they made it read-only in CFMX,
> since other
> variables in the thistag scope can still be set and
> modified, re:
> cfassociate, etc. In any event -- it's an issue I had to
> deal with
> myself. :) Documentation for cfassociate is pretty weak
> too -- I added
> some comments about that on MM's livedocs a little while
> ago.

> hth

> s. isaac dealey                214-823-9345

> team macromedia volunteer
> http://www.macromedia.com/go/team

> chief architect, tapestry cms  http://products.turnkey.to

> onTap is open source           http://www.turnkey.to/ontap



>> Wow - can you give a code snippet of where hasEndTag is
>> trying to be set ?



>> The thisTag scope holds a couple pieces of information
>> that are handy when
>> writing a custom tag.  The scope is only available when
>> you call a template
>> as a tag.



>> ThisTag.hasEndTag - bool telling you if the tag has an
>> end
>> tag

>> thisTag.ExecutionMode - tells you if it is executing the
>> beginning or the
>> end of the tag

>> thisTag.generatedContent - this contains all the
>> generated
>> html / content
>> that was generated between the start and end of a tag.









>> -----Original Message-----
>> From: [EMAIL PROTECTED]
>> [mailto:[EMAIL PROTECTED] On Behalf
>> Of Bruce Sorge
>> Sent: Thursday, January 15, 2004 3:27 PM
>> To: [EMAIL PROTECTED]
>> Subject: ThisTag attribute



>> Hello all. I have an application that I inherited that
>> was
>> written by a
>> contractor. It was written in CF5 and we just upgraded
>> our
>> dev environment
>> to CFMX 6.1, and this site is generating an error:

>> The HasEndTag variable in the ThisTag scope can not be
>> set
>> by the user.



>> I have never use the ThisTag scope so I am not sure what
>> it is doing. Can
>> someone shed some light? The on-line docs to not do much
>> good.





>> Thanks,



>> Bruce







> -----------------------------------------------
> To post, send email to [EMAIL PROTECTED]
> To unsubscribe:
>    Send UNSUBSCRIBE to [EMAIL PROTECTED]
> To subscribe / unsubscribe: http://www.dfwcfug.org



> -----------------------------------------------
> To post, send email to [EMAIL PROTECTED]
> To unsubscribe:
>    Send UNSUBSCRIBE to [EMAIL PROTECTED]
> To subscribe / unsubscribe: http://www.dfwcfug.org



s. isaac dealey                214-823-9345

team macromedia volunteer      http://www.macromedia.com/go/team

chief architect, tapestry cms  http://products.turnkey.to

onTap is open source           http://www.turnkey.to/ontap


-----------------------------------------------
To post, send email to [EMAIL PROTECTED]
To unsubscribe:
   Send UNSUBSCRIBE to [EMAIL PROTECTED]
To subscribe / unsubscribe: http://www.dfwcfug.org

Reply via email to