This is the main Smarty class
package | Smarty |
---|---|
subpackage | Template |
__call(string $name, array $args)
inherited_from | \Smarty_Internal_TemplateBase::__call() |
---|
string
unknown method-name
array
argument array
__clone()
__construct()
__destruct()
__get(string $name) : mixed
Calls the appropriate getter function. Issues an E_USER_NOTICE if no valid getter is found.
string
property name
mixed
__set(string $name, mixed $value)
Calls the appropriate setter function. Issues an E_USER_NOTICE if no valid setter is found.
string
property name
mixed
parameter passed to setter
_get_filter_name(callback $function_name) : string
inherited_from | \Smarty_Internal_TemplateBase::_get_filter_name() |
---|
callback
string
internal filter nameaddAutoloadFilters(array $filters, string $type) : \Smarty
array
filters to load automatically
string
"pre", "output", … specify the filter type to set. Defaults to none treating $filters' keys as the appropriate types
\Smarty
current Smarty instance for chainingaddConfigDir(string | array $config_dir, string $key) : \Smarty
string
array
directory(s) of config sources
string
key of the array element to assign the config dir to
\Smarty
current Smarty instance for chainingaddDefaultModifiers(array | string $modifiers) : \Smarty
array
string
modifier or list of modifiers to add
\Smarty
current Smarty instance for chainingaddTemplateDir(string | array $template_dir, string $key) : \Smarty
string
array
directory(s) of template sources
string
of the array element to assign the template dir to
\SmartyException |
when the given template directory is not valid |
---|
\Smarty
current Smarty instance for chainingappend(array | string $tpl_var, mixed $value, boolean $merge, boolean $nocache) : \Smarty_Internal_Data
inherited_from | \Smarty_Internal_Data::append() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::append() |
array
string
the template variable name(s)
mixed
the value to append
boolean
flag if array elements shall be merged
boolean
if true any output of this variable will be not cached
\Smarty_Internal_Data
current Smarty_Internal_Data (or Smarty or Smarty_Internal_Template) instance for chainingappendByRef(string $tpl_var, mixed $value, boolean $merge) : \Smarty_Internal_Data
inherited_from | \Smarty_Internal_Data::appendByRef() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::appendByRef() |
string
the template variable name
mixed
&$value the referenced value to append
boolean
flag if array elements shall be merged
\Smarty_Internal_Data
current Smarty_Internal_Data (or Smarty or Smarty_Internal_Template) instance for chainingassign(array | string $tpl_var, mixed $value, boolean $nocache) : \Smarty_Internal_Data
inherited_from | \Smarty_Internal_Data::assign() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::assign() |
array
string
the template variable name(s)
mixed
the value to assign
boolean
if true any output of this variable will be not cached
\Smarty_Internal_Data
current Smarty_Internal_Data (or Smarty or Smarty_Internal_Template) instance for chainingassignByRef(string $tpl_var, $value, boolean $nocache) : \Smarty_Internal_Data
inherited_from | \Smarty_Internal_Data::assignByRef() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::assignByRef() |
string
the template variable name
boolean
if true any output of this variable will be not cached
\Smarty_Internal_Data
current Smarty_Internal_Data (or Smarty or Smarty_Internal_Template) instance for chainingassignGlobal(string $varname, mixed $value, boolean $nocache) : \Smarty_Internal_Data
inherited_from | \Smarty_Internal_Data::assignGlobal() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::assignGlobal() |
string
the global variable name
mixed
the value to assign
boolean
if true any output of this variable will be not cached
\Smarty_Internal_Data
current Smarty_Internal_Data (or Smarty or Smarty_Internal_Template) instance for chainingclearAllAssign() : \Smarty_Internal_Data
inherited_from | \Smarty_Internal_Data::clearAllAssign() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::clearAllAssign() |
\Smarty_Internal_Data
current Smarty_Internal_Data (or Smarty or Smarty_Internal_Template) instance for chainingclearAllCache(integer $exp_time, string $type) : integer
integer
expiration time
string
resource type
integer
number of cache files deletedclearAssign(string | array $tpl_var) : \Smarty_Internal_Data
inherited_from | \Smarty_Internal_Data::clearAssign() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::clearAssign() |
string
array
the template variable(s) to clear
\Smarty_Internal_Data
current Smarty_Internal_Data (or Smarty or Smarty_Internal_Template) instance for chainingclearCache(string $template_name, string $cache_id, string $compile_id, integer $exp_time, string $type) : integer
string
template name
string
cache id
string
compile id
integer
expiration time
string
resource type
integer
number of cache files deletedclearCompiledTemplate(string $resource_name, string $compile_id, integer $exp_time) : integer
string
template name
string
compile id
integer
expiration time
integer
number of template files deletedclearConfig(string $varname) : \Smarty_Internal_Data
inherited_from | \Smarty_Internal_Data::clearConfig() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::clearConfig() |
string
variable name or null
\Smarty_Internal_Data
current Smarty_Internal_Data (or Smarty or Smarty_Internal_Template) instance for chainingcompileAllConfig($extention, bool $force_compile, int $time_limit, int $max_errors) : integer
bool
force all to recompile
int
int
integer
number of template files recompiledcompileAllTemplates($extention, bool $force_compile, int $time_limit, int $max_errors) : integer
bool
force all to recompile
int
int
integer
number of template files recompiledconfigLoad(string $config_file, mixed $sections) : \Smarty_Internal_Data
inherited_from | \Smarty_Internal_Data::configLoad() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::configLoad() |
string
filename
mixed
array of section names, single section or null
\Smarty_Internal_Data
current Smarty_Internal_Data (or Smarty or Smarty_Internal_Template) instance for chainingcreateData(object $parent)
returns | Smarty_Data data object |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::createData() |
object
next higher level of Smarty variables
createTemplate(string $template, mixed $cache_id, mixed $compile_id, object $parent, boolean $do_clone) : object
string
the resource handle of the template file
mixed
cache id to be used with this template
mixed
compile id to be used with this template
object
next higher level of Smarty variables
boolean
flag is Smarty object shall be cloned
object
template objectdisplay(string $template, mixed $cache_id, mixed $compile_id, object $parent)
inherited_from | \Smarty_Internal_TemplateBase::display() |
---|
string
the resource handle of the template file or template object
mixed
cache id to be used with this template
mixed
compile id to be used with this template
object
next higher level of Smarty variables
enableSecurity(string | \Smarty_Security $security_class) : \Smarty
\SmartyException |
when an invalid class name is provided |
---|
\Smarty
current Smarty instance for chainingfetch(string $template, mixed $cache_id, mixed $compile_id, object $parent, bool $display, bool $merge_tpl_vars, bool $no_output_filter) : string
inherited_from | \Smarty_Internal_TemplateBase::fetch() |
---|
string
the resource handle of the template file or template object
mixed
cache id to be used with this template
mixed
compile id to be used with this template
object
next higher level of Smarty variables
bool
true: display, false: fetch
bool
if true parent template variables merged in to local scope
bool
if true do not run output filter
string
rendered template outputgetAutoloadFilters(string $type) : array
string
type of filter to get autoloads for. Defaults to all autoload filters
array
array( 'type1' => array( 'filter1', 'filter2', … ) ) or array( 'filter1', 'filter2', …) if $type was specifiedgetCacheDir() : string
string
path of cache directorygetCompileDir() : string
string
path to compiled templatesgetConfigDir(mixed $index) : array | string
mixed
index of directory to get, null to get all
array
string
configuration directorygetConfigVariable(string $variable, $error_enable) : mixed
inherited_from | \Smarty_Internal_Data::getConfigVariable() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::getConfigVariable() |
string
the name of the config variable
mixed
the value of the config variablegetConfigVars(string $varname, $search_parents) : string
inherited_from | \Smarty_Internal_Data::getConfigVars() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::getConfigVars() |
string
variable name or null
string
variable value or or array of variablesgetDebugTemplate() : string
string
getDefaultModifiers() : array
array
list of default modifiersgetGlobal(string $varname) : string
string
variable name or null
string
variable value or or array of variablesgetPluginsDir() : array
array
list of plugin directoriesgetRegisteredObject(string $name) : object
inherited_from | \Smarty_Internal_TemplateBase::getRegisteredObject() |
---|
string
object name
\SmartyException |
if no such object is found |
---|
object
getStreamVariable(string $variable) : mixed
inherited_from | \Smarty_Internal_Data::getStreamVariable() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::getStreamVariable() |
string
the stream of the variable
mixed
the value of the stream variablegetTags(\Smarty_Internal_Template $template) : array
array
of tag/attributesgetTemplateDir(mixed $index) : array | string
mixed
index of directory to get, null to get all
array
string
list of template directories, or directory of $indexgetTemplateVars(string $varname, string $_ptr, boolean $search_parents) : string
inherited_from | \Smarty_Internal_Data::getTemplateVars() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::getTemplateVars() |
string
variable name or null
string
optional pointer to data object
boolean
include parent templates?
string
variable value or or array of variablesgetVariable(string $variable, object $_ptr, boolean $search_parents, $error_enable) : object
inherited_from | \Smarty_Internal_Data::getVariable() |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::getVariable() |
string
the name of the Smarty variable
object
optional pointer to data object
boolean
search also in parent data
object
the object of the variableisCached(string | object $template, mixed $cache_id, mixed $compile_id, object $parent) : boolean
inherited_from | \Smarty_Internal_TemplateBase::isCached() |
---|
string
object
the resource handle of the template file or template object
mixed
cache id to be used with this template
mixed
compile id to be used with this template
object
next higher level of Smarty variables
boolean
cache statusloadFilter(string $type, string $name)
inherited_from | \Smarty_Internal_TemplateBase::loadFilter() |
---|
string
filter type
string
filter name
\SmartyException |
if filter could not be loaded |
---|
loadPlugin(string $plugin_name, bool $check) : string
string
class plugin name to load
bool
check if already loaded
string
|boolean filepath of loaded file or falsemuteExpectedErrors() : void
mutingErrorHandler(integer $errno, $errstr, $errfile, $errline, $errcontext) : boolean
link | http://php.net/set_error_handler |
---|
integer
Error level
boolean
registerCacheResource(string $type, \Smarty_CacheResource $callback) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::registerCacheResource() |
---|
string
name of cache resource type
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingregisterClass($class_name, string $class_impl) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::registerClass() |
---|
string
the referenced PHP class to register
\SmartyException |
if $class_impl does not refer to an existing class |
---|
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingregisterDefaultConfigHandler(callable $callback) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::registerDefaultConfigHandler() |
---|
callable
class/method name
\SmartyException |
if $callback is not callable |
---|
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingregisterDefaultPluginHandler(callable $callback) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::registerDefaultPluginHandler() |
---|
callable
class/method name
\SmartyException |
if $callback is not callable |
---|
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingregisterDefaultTemplateHandler(callable $callback) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::registerDefaultTemplateHandler() |
---|
callable
class/method name
\SmartyException |
if $callback is not callable |
---|
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingregisterFilter(string $type, callback $callback) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::registerFilter() |
---|
string
filter type
callback
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingregisterObject($object_name, object $object_impl, array $allowed, boolean $smarty_args, array $block_methods) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::registerObject() |
---|
object
the referenced PHP object to register
array
list of allowed methods (empty = all)
boolean
smarty argument format, else traditional
array
list of block-methods
\SmartyException |
if any of the methods in $allowed or $block_methods are invalid |
---|
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingregisterPlugin(string $type, string $tag, callback $callback, boolean $cacheable, array $cache_attr) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::registerPlugin() |
---|
string
plugin type
string
name of template tag
callback
PHP callback to register
boolean
if true (default) this fuction is cachable
array
caching attributes if any
\SmartyException |
when the plugin tag is invalid |
---|
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingregisterResource(string $type, \Smarty_Resource | array $callback) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::registerResource() |
---|
string
name of resource type
\Smarty_Resource
array
or instance of Smarty_Resource, or array of callbacks to handle resource (deprecated)
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingsetAutoloadFilters(array $filters, string $type) : \Smarty
array
filters to load automatically
string
"pre", "output", … specify the filter type to set. Defaults to none treating $filters' keys as the appropriate types
\Smarty
current Smarty instance for chainingsetCacheDir(string $cache_dir) : \Smarty
string
directory to store cached templates in
\Smarty
current Smarty instance for chainingsetCompileDir(string $compile_dir) : \Smarty
string
directory to store compiled templates in
\Smarty
current Smarty instance for chainingsetDebugTemplate(string $tpl_name) : \Smarty
string
\SmartyException |
if file is not readable |
---|
\Smarty
current Smarty instance for chainingsetDefaultModifiers(array | string $modifiers) : \Smarty
array
string
modifier or list of modifiers to set
\Smarty
current Smarty instance for chainingsetPluginsDir(string | array $plugins_dir) : \Smarty
string
array
directory(s) of plugins
\Smarty
current Smarty instance for chainingsetTemplateDir(string | array $template_dir) : \Smarty
string
array
directory(s) of template sources
\Smarty
current Smarty instance for chainingtemplateExists(string $resource_name) : boolean
string
template name
boolean
statustestInstall(array $errors) : boolean
array
Array to write errors into, rather than outputting them
boolean
true if setup is fine, false if something is wrongunloadFilter(string $type, string $name) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::unloadFilter() |
---|
string
filter type
string
filter name
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingunmuteExpectedErrors() : void
unregisterCacheResource(string $type) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::unregisterCacheResource() |
---|
string
name of cache resource type
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingunregisterFilter(string $type, callback $callback) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::unregisterFilter() |
---|
string
filter type
callback
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingunregisterObject(string $name) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::unregisterObject() |
---|
string
object name
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingunregisterPlugin(string $type, string $tag) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::unregisterPlugin() |
---|
string
of plugin
string
name of plugin
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingunregisterResource(string $type) : \Smarty_Internal_Templatebase
inherited_from | \Smarty_Internal_TemplateBase::unregisterResource() |
---|
string
name of resource type
\Smarty_Internal_Templatebase
current Smarty_Internal_Templatebase (or Smarty or Smarty_Internal_Template) instance for chainingreplaceCamelcase(string $match) : string
inherited_from | \Smarty_Internal_TemplateBase::replaceCamelcase() |
---|
string
match string
string
replacemant$_CHARSET
"UTF-8")
$_DATE_FORMAT
$_IS_WINDOWS
$_MBSTRING
$_UTF8_MODIFIER
$_cacheresource_handlers : array
$_current_file : string
$_dir_perms : int
$_file_perms : int
$_muted_directories
$_parserdebug : bool
$_previous_error_handler
$_resource_handlers : array
$_smarty_vars : array
$_tag_stack : array
$allow_ambiguous_resources : boolean
$allow_php_templates : bool
$auto_literal : boolean
$autoload_filters : array
$cache_id : string
$cache_lifetime : integer
$cache_locking : boolean
$cache_modified_check : boolean
$caching : boolean
$caching_type : string
Must be an element of $cache_resource_types.
$compile_check : boolean
$compile_id : string
$compile_locking : boolean
$config_booleanize : boolean
$config_overwrite : boolean
$config_read_hidden : boolean
$config_vars : array
inherited_from | \Smarty_Internal_Data::$$config_vars |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::$$config_vars |
$debug_tpl : string
$debugging : boolean
Setting this to true enables the debug-console.
$debugging_ctrl : string
$default_config_handler_func : callable
$default_config_type : string
$default_modifiers : array
$default_plugin_handler_func : callable
$default_resource_type : string
Must be an valid key of $registered_resources.
$default_template_handler_func : callable
$direct_access_security : boolean
{@internal Currently used by Smarty_Internal_Template only. }}
$error_reporting : int
$error_unassigned : boolean
$escape_html : boolean
$force_cache : boolean
$force_compile : boolean
$global_tpl_vars
$joined_config_dir : string
$joined_template_dir : string
$left_delimiter : string
$locking_timeout : float
$merge_compiled_includes : boolean
$merged_templates_func : array
$parent : \Smarty_Internal_Template
inherited_from | \Smarty_Internal_Data::$$parent |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::$$parent |
$php_handling : integer
$plugin_search_order : array
$properties : array
$registered_cache_resources : array
$registered_classes : array
$registered_filters : array
$registered_objects : array
$registered_plugins : array
$registered_resources : array
$right_delimiter : string
$security_class : string
This should be instance of Smarty_Security.
see | \Smarty_Security |
---|
$security_policy : \Smarty_Security
$smarty : \Smarty
$smarty_debug_id : \type
Only used when $debugging_ctrl is set to 'URL'. The name of the URL-parameter that activates debugging.
$start_time : int
$template_class : string
inherited_from | \Smarty_Internal_Data::$$template_class |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::$$template_class |
$template_functions : array
$template_objects : array
$tpl_vars : array
inherited_from | \Smarty_Internal_Data::$$tpl_vars |
---|---|
inherited_from | \Smarty_Internal_TemplateBase::$$tpl_vars |
$use_include_path : boolean
$use_sub_dirs : boolean
$cache_dir : string
$compile_dir : string
$config_dir : array
$plugins_dir : array
$template_dir : array
CACHING_LIFETIME_CURRENT
CACHING_LIFETIME_SAVED
CACHING_OFF
COMPILECHECK_CACHEMISS
COMPILECHECK_OFF
COMPILECHECK_ON
FILTER_OUTPUT
FILTER_POST
FILTER_PRE
FILTER_VARIABLE
PHP_ALLOW
PHP_PASSTHRU
.. ?>" tags in templates.
PHP_QUOTE
PHP_REMOVE
PLUGIN_BLOCK
PLUGIN_COMPILER
PLUGIN_FUNCTION
PLUGIN_MODIFIER
PLUGIN_MODIFIERCOMPILER
SCOPE_GLOBAL
SCOPE_LOCAL
SCOPE_PARENT
SCOPE_ROOT
SMARTY_VERSION