Warning: This page has not been updated in over over a year and may be outdated or deprecated.
development:plugins:view_helpers
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
vufind2:building_a_view_helper [2014/06/13 13:14] – external edit 127.0.0.1 | development:plugins:view_helpers [2020/03/13 19:48] – demiankatz | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== | + | ====== View Helpers |
- | View helpers are a convenient way of encapsulating logic that is useful during template rendering. | + | ===== Building a View Helper ===== |
+ | |||
+ | View helpers are a convenient way of encapsulating logic that is useful during template rendering. | ||
Creating a view helper is simple: | Creating a view helper is simple: | ||
- | * Pick a namespace for your view helpers. | + | * Pick a namespace for your view helpers. |
- | * In your chosen namespace, create a class that extends \Zend\View\Helper\AbstractHelper. | + | * In your chosen namespace, create a class that extends \Laminas\View\Helper\AbstractHelper. |
- | * Create a [[customizing the user interface|custom theme]] if you have not done so already. | + | * Create a [[development: |
- | * Configure the new helper in the ' | + | * Configure the new helper in the ' |
---- struct data ---- | ---- struct data ---- | ||
---- | ---- | ||
development/plugins/view_helpers.txt · Last modified: 2020/03/19 21:53 by crhallberg