aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/smarty/smarty/NEW_FEATURES.txt
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/smarty/smarty/NEW_FEATURES.txt')
-rw-r--r--vendor/smarty/smarty/NEW_FEATURES.txt57
1 files changed, 51 insertions, 6 deletions
diff --git a/vendor/smarty/smarty/NEW_FEATURES.txt b/vendor/smarty/smarty/NEW_FEATURES.txt
index adbc1099b..7632b07ea 100644
--- a/vendor/smarty/smarty/NEW_FEATURES.txt
+++ b/vendor/smarty/smarty/NEW_FEATURES.txt
@@ -2,6 +2,53 @@
This file contains a brief description of new features which have been added to Smarty 3.1
+Smarty 3.1.32 New tags for inheritance parent and child
+ =========================================
+ {parent} == {$smarty.block.parent}
+ {child} == {$smarty.block.child}
+ Both tags support the assign attribute like
+ {child assign=foo}
+
+ Deprecate functions Smarty::muteExpectedErrors() and Smarty::unmuteExpectedErrors()
+ ===================================================================================
+ These functions to start a special error handler are no longer needed as Smarty does
+ no longer use error suppression like @filemtime().
+ For backward compatibility the functions still can be called.
+
+ Using literals containing Smarty's left and right delimiter
+ ===========================================================
+ New Methods
+ $smarty->setLiterals(array $literals)
+ $smarty->addLiterals(array $literals)
+ to define literals containing Smarty delimiter. This can avoid the need for extreme usage
+ of {literal} {/literal} tags.
+ A) Treat '{{' and '}}' as literal
+ If Smarty::$auto_literal is enabled
+ {{ foo }}
+ will be treated now as literal. (This does apply for any number of delimiter repeatations).
+ However {{foo}} is not an literal but will be interpreted as a recursive Smarty tag.
+ If you use
+ $smarty->setLiteral(array('{{','}}'));
+ {{foo}} is now a literal as well.
+ NOTE: In the last example nested Smarty tags starting with '{{' or ending with '}}' will not
+ work any longer, but this should be very very raw occouring restriction.
+ B) Example 2
+ Assume your delimiter are '<-' , '->' and '<--' , '-->' shall be literals
+ $smarty->setLiteral(array('<--','-->'));
+
+
+ The capture buffers can now be accessed as array
+ ================================================
+ {capture name='foo'}
+ bah
+ {\capture}
+ {capture name='buh'}
+ blar
+ {\capture}
+ {foreach $smarty.capture as $name => $buffer}
+ ....
+ {/foreach}
+
Smarty 3.1.31
New tags for inheritance parent and child
=========================================
@@ -45,8 +92,7 @@ Smarty 3.1.30
{/foreach}
The {foreach} loop is rendered while processing the compiled template, but $current is a nocache
- variable. Normally the {if $current==$item.id} would fail as the $item variable is unkown in the
- cached template. {make_nocache $item} does make the current $item value known in thee cached template.
+ variable. Normally the {if $current==$item.id} would fail as the $item variable is unknown in the cached template. {make_nocache $item} does make the current $item value known in thee cached template.
{make_nocache} is ignored when caching is disabled or the variable does exists as nocache variable.
@@ -81,8 +127,7 @@ Smarty 3.1.30
Supported scope are parent, tpl_root, smarty, global and root.
A scope used together with the {include} tag will cause that with some exceptions any variable
assignment within that sub-template will update/assign the variable in other scopes according
- to the above rules. It does include also variables assigned by plugins, tags supporting the assign=foo
- attribute and direct assignments in {if} and {while} like {if $foo=$bar}.
+ to the above rules. It does include also variables assigned by plugins, tags supporting the assign=foo attribute and direct assignments in {if} and {while} like {if $foo=$bar}.
Excluded are the key and value variables of {foreach}, {for} loop variables , variables passed by attributes
in {include} and direct increments/decrements like {$foo++}, {$foo--}
@@ -132,8 +177,8 @@ Smarty 3.1.28
as the corresponding Smarty methods to get the content of another template.
Example:
$template->display(); Does display template of template object
- $template->display('foo.tpl'); Does display template 'foo.bar'
-
+ $template->display('foo.tpl'); Does display template 'foo.bar'
+
File: resource
==============
Multiple template_dir entries can now be selected by a comma separated list of indices.