User Guide
cfinclude 233
You can specify a variable for the template attribute, as the following example shows:
<cfset templatetouse="../header/header.cfm">
<cfinclude template="#templatetouse#">
Example
<!--- This example shows the use of cfinclude to paste CFML
or HTML code into another page dynamically. --->
<h4>This example includes the dochome.htm page from the CFDOCS directory.
The images do not display, because they are located in
a separate directory. However, the page appears fully rendered
within the contents of this page.</h4>
<cfinclude template = "../cfdocs/dochome.htm">