mirror of
https://github.com/twigphp/Twig.git
synced 2026-09-15 11:56:50 +00:00
updated doc for the pre_escape filter option
This commit is contained in:
committed by
Fabien Potencier
parent
d35e19fe22
commit
c34dee83f2
@@ -343,6 +343,12 @@ set the `is_safe` option:
|
||||
[php]
|
||||
$filter = new Twig_Filter_Function('nl2br', array('is_safe' => array('html')));
|
||||
|
||||
Some advanced filters may have to work on already escaped or safe values. In
|
||||
such a case, set the `pre_escape` option:
|
||||
|
||||
[php]
|
||||
$filter = new Twig_Filter_Function('somefilter', array('pre_escape' => 'html', 'is_safe' => array('html')));
|
||||
|
||||
Overriding default Filters
|
||||
--------------------------
|
||||
|
||||
|
||||
Reference in New Issue
Block a user