%PDF- %PDF-
Direktori : /var/www/html/bbw/farmaci/kritik-portale/module/ReviewBase/src/ReviewBase/View/Helper/ |
Current File : /var/www/html/bbw/farmaci/kritik-portale/module/ReviewBase/src/ReviewBase/View/Helper/RouteName.php |
<?php /** * Description of RouteName * * @author Florian Koller ( conlabz GmbH ) <florian.koller at conlabz.de> */ namespace ReviewBase\View\Helper; use Zend\View\Helper\AbstractHelper; class RouteName extends AbstractHelper { protected $router = null; protected $request = null; public function __construct($serviceManager) { $this->router = $serviceManager->get('router'); $this->request = $serviceManager->get('request'); } public function __invoke($ownerID = null) { $routeName = ""; $matchedRoute = $this->router->match($this->request); if(!is_null($matchedRoute)){ $routeName = $matchedRoute->getMatchedRouteName(); } return $routeName; } }