Global navigation

   Documentation Center
   eZ Studio & eZ Platform
     User Manual
     Technical Manual
     Glossary
   eZ Publish 4.x / legacy

 
eZ Publish (5.x)

eZ Publish 5.x | For eZ Platform & eZ Studio topics see Technical manual and User manual, for eZ Publish 4.x and Legacy topics see eZ Publish legacy

Skip to end of metadata
Go to start of metadata

It is possible to dynamically inject variables in content view templates by listening to the ezpublish.pre_content_view event.

The event listener method receives an eZ\Publish\Core\MVC\Symfony\Event\PreContentViewEvent object

Example

The following example will inject foo and osTypes variables in all content view templates.

Service configuration

 

 

  • No labels