template::themed_template (public)
template::themed_template [ -verbose ] path
Defined in packages/acs-templating/tcl/util-procs.tcl
Given a path like /packages/acs-admin/www/index pointing to an .adp file, this function tries to locate this path in the ResourceDir of the subsite (determined by the theme). If found the themed template is returned, otherwise the passed template path.
- Switches:
- -verbose (optional, boolean, defaults to
"false"
)- Parameters:
- path (required)
- absolute path within the open acs tree (without extension)
- Returns:
- path to themed template or input value (without extension)
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
Source code: if {[string index $path 0] eq "/"} { set style [string range $path 1 end] } else { set style $path } set stub [template::resource_path {*}[expr {$verbose_p ? "-verbose" : ""}] -type templates -style $style -relative] if {[file readable $::acs::rootdir/$stub.adp]} { if {$verbose_p} { ns_log notice "themed_template: found template in $stub" } return $stub } else { if {$verbose_p} { ns_log notice "themed_template: no themed template found for '$path'" } } return $pathXQL Not present: Generic, PostgreSQL, Oracle