Class icms_view_theme_Object
Builds the theme components
Methods summary
public
boolean
|
#
xoInit( array $options = array() )
Initializes this theme
Upon initialization, the theme creates its template engine and instanciates the
plug-ins from the specified icms_view_theme_Object::$plugins list. If the theme is a 2.0 theme, that does not
display redirection messages, the HTTP redirections system is disabled to ensure users will
see the redirection screen.
Parameters
Returns
boolean
Tasktype
10 Initialization
|
public
string
|
#
generateCacheId( string $cache_id, string $extraString = '' )
Generate cache id based on extra information of language and user groups
Generate cache id based on extra information of language and user groups
User groups other than anonymous should be detected to avoid disclosing group sensitive contents
Parameters
- $cache_id
- raw cache id
- $extraString
- extra string
Returns
string complete cache id
|
public
boolean
|
#
checkCache( )
Checks cache for a changed version of the template and renders template
Checks cache for a changed version of the template and renders template
Returns
boolean
|
public
|
#
render( string $canvasTpl = NULL, string $pageTpl = NULL, string $contentTpl = NULL, array $vars = array() )
Render the page
The theme engine builds pages from 2 templates: canvas and content.
A module can call this method directly and specify what templates the theme engine must use.
If render() hasn't been called before, the theme defaults will be used for the canvas and
page template (and xoopsOption['template_main'] for the content).
Parameters
- $canvasTpl
- The canvas template, if different from the theme default
- $pageTpl
- The page template, if different from the theme default (unsupported, 2.3+ only)
- $contentTpl
- The content template
- $vars
- Template variables to send to the template engine
|
public
|
#
addScript( string $src = '', array $attributes = array(), string $content = '', str $zone = 'module', integer $weight = 0 )
Adds script code to the document head
Adds script code to the document head
This methods allows the insertion of an external script file (if $src is provided), or
of a script snippet. The file URI is parsed to take benefit of the theme resource
overloading system.
The $attributes parameter allows you to specify the attributes that will be added to the
inserted
|