projects
/
web/konrad/twig.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
1b46f06
)
fixed typo in doc
author
Fabien Potencier
<fabien.potencier@gmail.com>
Fri, 28 Oct 2011 15:23:01 +0000 (17:23 +0200)
committer
Fabien Potencier
<fabien.potencier@gmail.com>
Fri, 28 Oct 2011 15:23:01 +0000 (17:23 +0200)
doc/advanced.rst
patch
|
blob
|
history
diff --git
a/doc/advanced.rst
b/doc/advanced.rst
index
96d7697
..
1fa3e83
100644
(file)
--- a/
doc/advanced.rst
+++ b/
doc/advanced.rst
@@
-164,7
+164,7
@@
Adding a filter is as simple as calling the ``addFilter()`` method on the
``Twig_Environment`` instance::
$twig = new Twig_Environment($loader);
- $twig->addFilter('rot13', new Twig_Filter_Function('rot13'));
+ $twig->addFilter('rot13', new Twig_Filter_Function('str_rot13'));
The second argument of ``addFilter()`` is an instance of ``Twig_Filter``.
Here, we use ``Twig_Filter_Function`` as the filter is a PHP function. The