var/cache/website/dev/twig/6f/6fb1163233a4d86356b720d06dc4e282.php line 59

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\SandboxExtension;
  6. use Twig\Markup;
  7. use Twig\Sandbox\SecurityError;
  8. use Twig\Sandbox\SecurityNotAllowedTagError;
  9. use Twig\Sandbox\SecurityNotAllowedFilterError;
  10. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  11. use Twig\Source;
  12. use Twig\Template;
  13. /* pages/components/header.html.twig */
  14. class __TwigTemplate_acc64d801e405c8f5a3c014cba3c5b40 extends Template
  15. {
  16.     private $source;
  17.     private $macros = [];
  18.     public function __construct(Environment $env)
  19.     {
  20.         parent::__construct($env);
  21.         $this->source $this->getSourceContext();
  22.         $this->parent false;
  23.         $this->blocks = [
  24.         ];
  25.     }
  26.     protected function doDisplay(array $context, array $blocks = [])
  27.     {
  28.         $macros $this->macros;
  29.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  30.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""pages/components/header.html.twig"));
  31.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  32.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""pages/components/header.html.twig"));
  33.         // line 1
  34.         $context["selected"] = 0;
  35.         echo 
  36. ";
  37.         // line 2
  38.         $context["homelink"] = twig_get_attribute($this->env$this->source, (isset($context["request"]) || array_key_exists("request"$context) ? $context["request"] : (function () { throw new RuntimeError('Variable "request" does not exist.'2$this->source); })()), "resourceLocatorPrefix", [], "any"falsefalsefalse2);
  39.         echo 
  40. ";
  41.         // line 3
  42.         $context["loginlink"] = (("/" twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source, (isset($context["app"]) || array_key_exists("app"$context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.'3$this->source); })()), "request", [], "any"falsefalsefalse3), "locale", [], "any"falsefalsefalse3)) . "/login");
  43.         // line 4
  44.         $context["loginImg"] = "data/img/menu_login.png";
  45.         // line 5
  46.         $context["carrentUser"] = "";
  47.         // line 7
  48.         if (array_key_exists("uuid"$context)) {
  49.             // line 8
  50.             $context["selected"] = $this->extensions['App\Twig\ComponentDataAdapterExtension']->adaptAttribute("header.selected", ["currentUuid" => (isset($context["uuid"]) || array_key_exists("uuid"$context) ? $context["uuid"] : (function () { throw new RuntimeError('Variable "uuid" does not exist.'8$this->source); })())]);
  51.         }
  52.         // line 10
  53.         if (twig_get_attribute($this->env$this->source, (isset($context["app"]) || array_key_exists("app"$context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.'10$this->source); })()), "user", [], "any"falsefalsefalse10)) {
  54.             // line 11
  55.             $context["carrentUser"] = twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source, (isset($context["app"]) || array_key_exists("app"$context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.'11$this->source); })()), "user", [], "any"falsefalsefalse11), "username", [], "any"falsefalsefalse11);
  56.         }
  57.         // line 13
  58.         echo "<modern-header
  59.         links=\"";
  60.         // line 14
  61.         echo twig_escape_filter($this->envjson_encode($this->extensions['App\Twig\ComponentDataAdapterExtension']->adaptAttribute("header.links", ["locale" => twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source, (isset($context["app"]) || array_key_exists("app"$context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.'14$this->source); })()), "request", [], "any"falsefalsefalse14), "locale", [], "any"falsefalsefalse14)])), "html"nulltrue);
  62.         echo "\"
  63.         selected=\"";
  64.         // line 15
  65.         echo twig_escape_filter($this->env, (isset($context["selected"]) || array_key_exists("selected"$context) ? $context["selected"] : (function () { throw new RuntimeError('Variable "selected" does not exist.'15$this->source); })()), "html"nulltrue);
  66.         echo "\"
  67.         logo-link=\"";
  68.         // line 16
  69.         echo twig_escape_filter($this->envjson_encode(["url" => $this->extensions['Sulu\Bundle\WebsiteBundle\Twig\Content\ContentPathTwigExtension']->getContentRootPath(), "imageUrl" => "data/img/menu_logo.png"]), "html"nulltrue);
  70.         echo "\"
  71.         home-link=\"";
  72.         // line 17
  73.         echo twig_escape_filter($this->envjson_encode(["url" => (isset($context["homelink"]) || array_key_exists("homelink"$context) ? $context["homelink"] : (function () { throw new RuntimeError('Variable "homelink" does not exist.'17$this->source); })()), "imageUrl" => "data/img/menu_home.png"]), "html"nulltrue);
  74.         echo "\"
  75.         search-link=\"";
  76.         // line 18
  77.         echo twig_escape_filter($this->envjson_encode(["url" => "/""imageUrl" => "data/img/menu_search.png"]), "html"nulltrue);
  78.         echo "\"
  79.         user-link=\"";
  80.         // line 19
  81.         echo twig_escape_filter($this->envjson_encode(["url" => (isset($context["loginlink"]) || array_key_exists("loginlink"$context) ? $context["loginlink"] : (function () { throw new RuntimeError('Variable "loginlink" does not exist.'19$this->source); })()), "imageUrl" => (isset($context["loginImg"]) || array_key_exists("loginImg"$context) ? $context["loginImg"] : (function () { throw new RuntimeError('Variable "loginImg" does not exist.'19$this->source); })())]), "html"nulltrue);
  82.         echo "\"
  83.         localizations=\"";
  84.         // line 20
  85.         echo twig_escape_filter($this->envjson_encode((isset($context["localizations"]) || array_key_exists("localizations"$context) ? $context["localizations"] : (function () { throw new RuntimeError('Variable "localizations" does not exist.'20$this->source); })())), "html"nulltrue);
  86.         echo "\"
  87.         carrent-language=\"";
  88.         // line 21
  89.         echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["request"]) || array_key_exists("request"$context) ? $context["request"] : (function () { throw new RuntimeError('Variable "request" does not exist.'21$this->source); })()), "resourceLocatorPrefix", [], "any"falsefalsefalse21), "html"nulltrue);
  90.         echo "\"
  91.         current-user=\"";
  92.         // line 22
  93.         echo twig_escape_filter($this->env, (isset($context["carrentUser"]) || array_key_exists("carrentUser"$context) ? $context["carrentUser"] : (function () { throw new RuntimeError('Variable "carrentUser" does not exist.'22$this->source); })()), "html"nulltrue);
  94.         echo "\"
  95.         social-media=\"";
  96.         // line 23
  97.         echo twig_escape_filter($this->envjson_encode($this->extensions['App\Twig\ComponentDataAdapterExtension']->adaptAttribute("header.social_media", ["areaKey" => "footerSocialMediaLinks"])), "html"nulltrue);
  98.         echo "\"
  99.         ";
  100.         // line 24
  101.         $this->loadTemplate("pages/components/attributes/theme.html.twig""pages/components/header.html.twig"24)->display($context);
  102.         // line 25
  103.         echo "        ";
  104.         $this->loadTemplate("pages/components/attributes/overlay.html.twig""pages/components/header.html.twig"25)->display($context);
  105.         // line 26
  106.         echo "></modern-header>";
  107.         
  108.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  109.         
  110.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  111.     }
  112.     public function getTemplateName()
  113.     {
  114.         return "pages/components/header.html.twig";
  115.     }
  116.     public function isTraitable()
  117.     {
  118.         return false;
  119.     }
  120.     public function getDebugInfo()
  121.     {
  122.         return array (  115 => 26,  112 => 25,  110 => 24,  106 => 23,  102 => 22,  98 => 21,  94 => 20,  90 => 19,  86 => 18,  82 => 17,  78 => 16,  74 => 15,  70 => 14,  67 => 13,  64 => 11,  62 => 10,  59 => 8,  57 => 7,  55 => 5,  53 => 4,  51 => 3,  47 => 2,  43 => 1,);
  123.     }
  124.     public function getSourceContext()
  125.     {
  126.         return new Source("{% set selected = 0 %} 
  127. {% set homelink = request.resourceLocatorPrefix %} 
  128. {% set loginlink = '/' ~ app.request.locale ~ '/login' %}
  129. {% set loginImg = 'data/img/menu_login.png' %}
  130. {% set carrentUser = '' %}
  131. {%- if uuid is defined -%}
  132.         {% set selected = adapt_attribute('header.selected', {'currentUuid' : uuid}) %}       
  133. {%- endif -%}
  134. {%- if app.user -%}
  135.         {% set carrentUser = app.user.username %}
  136. {%- endif -%}
  137. <modern-header
  138.         links=\"{{ adapt_attribute('header.links', {'locale':app.request.locale}) | json_encode }}\"
  139.         selected=\"{{ selected }}\"
  140.         logo-link=\"{{ { 'url': sulu_content_root_path(), 'imageUrl': 'data/img/menu_logo.png' } | json_encode }}\"
  141.         home-link=\"{{ { 'url': homelink, 'imageUrl': 'data/img/menu_home.png' } | json_encode }}\"
  142.         search-link=\"{{ { 'url': '/', 'imageUrl': 'data/img/menu_search.png' } | json_encode }}\"
  143.         user-link=\"{{ { 'url': loginlink, 'imageUrl': loginImg } | json_encode }}\"
  144.         localizations=\"{{localizations | json_encode }}\"
  145.         carrent-language=\"{{request.resourceLocatorPrefix}}\"
  146.         current-user=\"{{carrentUser}}\"
  147.         social-media=\"{{ adapt_attribute('header.social_media', {'areaKey': 'footerSocialMediaLinks'}) | json_encode }}\"
  148.         {% include 'pages/components/attributes/theme.html.twig' %}
  149.         {% include 'pages/components/attributes/overlay.html.twig' %}
  150. ></modern-header>""pages/components/header.html.twig""/var/www/modern-expo.com/templates/pages/components/header.html.twig");
  151.     }
  152. }