Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Updated custom view helper config snippet

Updated the snippet for registering a custom view helper from a module config file.
  • Loading branch information...
commit 2b96f792f801b2d792348b2438f6fbef7a708ccf 1 parent 0a61bb2
@MidnightDesign MidnightDesign authored
Showing with 6 additions and 8 deletions.
  1. +6 −8 docs/languages/en/modules/zend.view.helpers.rst
View
14 docs/languages/en/modules/zend.view.helpers.rst
@@ -140,14 +140,12 @@ Within an MVC application, you will typically simply pass a map of plugins to th
// From within a configuration file
return array(
- 'di' => array('instance' => array(
- 'Zend\View\HelperLoader' => array('parameters' => array(
- 'map' => array(
- 'lowercase' => 'My\Helper\LowerCase',
- 'uppercase' => 'My\Helper\UpperCase',
- ),
- )),
- )),
+ 'view_helpers' => array(
+ 'invokables' => array(
+ 'lowercase' => 'My\Helper\LowerCase',
+ 'uppercase' => 'My\Helper\UpperCase',
+ ),
+ ),
);
The above can be done in each module that needs to register helpers with the ``PhpRenderer``; however, be aware
Please sign in to comment.
Something went wrong with that request. Please try again.