Documentation

Tpl_Processor
in package

TPL.

$return = Tpl_Processor::instance() ->tpl('TplName') ->process();

echo $return;

Tags
subpackage

Tpl

version
7.x
author

Hostmake LLC

copyright

© 2005-2024 ООО "Хостмэйк" (Hostmake LLC), http://www.hostcms.ru

Table of Contents

Properties

$instance  : mixed
The singleton instances.
$_entities  : array<string|int, mixed>
List of children entities
$_smarty  : Smarty
$_tpl  : Xsl_Model
XSL
$_vars  : array<string|int, mixed>
Variables/objects to the TPL-template

Methods

clear()  : self
Clear XSL
clearCompiledTemplate()  : self
Clear entire compile directory
entities()  : self
Set entities
format()  : string
Format TPL variables
getTemplateVars()  : mixed
getTemplateVars
getTpl()  : Tpl_Model
Get TPL
hideOutput()  : mixed
Hide Function Output e.g. {$object->xyz()|hideOutput}
instance()  : object
Register an existing instance as a singleton.
process()  : mixed
Execute processor
tpl()  : self
Set XSL
vars()  : self
Set vars
__construct()  : mixed
Constructor.

Properties

$instance

The singleton instances.

public static mixed $instance = \NULL

$_entities

List of children entities

protected array<string|int, mixed> $_entities = array()

$_vars

Variables/objects to the TPL-template

protected array<string|int, mixed> $_vars = array()

Methods

clear()

Clear XSL

public clear() : self
Return values
self

clearCompiledTemplate()

Clear entire compile directory

public clearCompiledTemplate() : self
Return values
self

entities()

Set entities

public entities(array<string|int, mixed> $entities) : self
Parameters
$entities : array<string|int, mixed>
Return values
self

format()

Format TPL variables

public format() : string
Return values
string

getTemplateVars()

getTemplateVars

public static getTemplateVars(mixed $params, mixed $smarty) : mixed
Parameters
$params : mixed
$smarty : mixed

hideOutput()

Hide Function Output e.g. {$object->xyz()|hideOutput}

public static hideOutput(mixed $str) : mixed
Parameters
$str : mixed

instance()

Register an existing instance as a singleton.

public static instance() : object
Return values
object

process()

Execute processor

public process() : mixed
Tags
hostcms-event

Tpl_Processor.onBeforeProcess

hostcms-event

Tpl_Processor.onAfterProcess

vars()

Set vars

public vars(array<string|int, mixed> $vars) : self
Parameters
$vars : array<string|int, mixed>
Return values
self

__construct()

Constructor.

protected __construct() : mixed

        
On this page

Search results