|
CFSETTING ENABLECFOUTPUTONLY="Yes" SHOWDEBUGOUTPUT="No"
SPECIALIZED FILE FOR USE IN CUSTOM TAG FOLDER
call it blackbox.cfm and your files will live in customtags/blackbox/module1_etc
Revised 1/8/03 by Dan Chick, Byron Bignell.
CFPARAM NAME="attributes.TOOL" DEFAULT=""
CFPARAM NAME="attributes.action" DEFAULT=""
CFSCRIPT
if (trim(attributes.action EQ "") AND Find(".", attributes.tool)){
attributes.action = listdeleteat(attributes.tool, 1, ".");
attributes.tool = listfirst(attributes.tool, ".");
}
diskpath = replacenocase(GetCurrentTemplatePath(), ".cfm", "\");
dir = "#listfirst(listlast(GetCurrentTemplatePath(),"\"),".")#\";
if (Find(".", ATTRIBUTES.action)){
extension = "";
}else{
extension = ".cfm";
}
/CFSCRIPT
CFSETTING ENABLECFOUTPUTONLY="No" SHOWDEBUGOUTPUT="No"
CFIF FileExists("#DiskPath##ATTRIBUTES.tool#/#ATTRIBUTES.ACTION##extension#")
CF IF FileExists("#DiskPath##ATTRIBUTES.tool#/bbsettings.cfm")
CF INCLUDE TEMPLATE="#dir##ATTRIBUTES.tool#\bbsettings.cfm"
/CFIF>
CFINCLUDE TEMPLATE="#dir##ATTRIBUTES.tool#\#ATTRIBUTES.ACTION##extension#"
CFELSE
CFOUTPUT
Couldn't find #diskpath##ATTRIBUTES.tool#/#ATTRIBUTES.ACTION##extension#
/CFOUTPUT
/CFIF/*
| |
|