PHP Class Contao\CoreBundle\EventListener\ToggleViewListener

Inheritance: use trait Contao\CoreBundle\Framework\ScopeAwareTrait
Afficher le fichier Open project: contao/core-bundle Class Usage Examples

Méthodes publiques

Méthode Description
__construct ( Contao\CoreBundle\Framework\ContaoFrameworkInterface $framework ) Constructor.
onKernelRequest ( GetResponseEvent $event ) Toggles the TL_VIEW cookie and redirects back to the referring page.

Private Methods

Méthode Description
getCookie ( string $value, string $basePath ) : Cookie Generates the TL_VIEW cookie based on the toggle_view value.

Method Details

__construct() public méthode

Constructor.
public __construct ( Contao\CoreBundle\Framework\ContaoFrameworkInterface $framework )
$framework Contao\CoreBundle\Framework\ContaoFrameworkInterface

onKernelRequest() public méthode

Toggles the TL_VIEW cookie and redirects back to the referring page.
public onKernelRequest ( GetResponseEvent $event )
$event Symfony\Component\HttpKernel\Event\GetResponseEvent