getBaseTagData

Used within a custom tag. Finds calling (ancestor) tag by
name and accesses its data.

getBaseTagData(tagname [, instancenumber]) → returns any

getBaseTagData Argument Reference

tagname string
Required

Specify the parent tag name, starting with CF_

instancenumber numeric
Default: 1

Specify the nth-level ancestor to retrieve variables from

Links more information about getBaseTagData

Examples sample code invoking the getBaseTagData function

Use getBaseTagData() to retrieve the execution mode of the parent CF_MAPPER custom tag.

<cfset tagData = getBaseTagData('CF_MAPPER')>
<!--- Find the tag's execution mode Located inside the --->
<cfif tagData.thisTag.executionMode neq 'inactive'>
template
<cfelse>
BODY
</cfif>

Use getBaseTagData() to retrieve the attributes of the parent cf_iframe tag

variables.parentAttributes = getBaseTagData('cf_iframe').attributes;

Fork me on GitHub