var/cache/dev/twig/c2/c2c0d7dff297855fd1392cd7b9f9edba8c3d28720b87efa9d45ff4af75e635ac.php line 33

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. /* @VisualMediaBreadcrumb/Breadcrumb/breadcrumb.html.twig */
  14. class __TwigTemplate_66dd6202c287c2cbed9cf3c7f704b480d666621b91cda9c697f91bd352cac9fa extends \Twig\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_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  30.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@VisualMediaBreadcrumb/Breadcrumb/breadcrumb.html.twig"));
  31.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  32.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@VisualMediaBreadcrumb/Breadcrumb/breadcrumb.html.twig"));
  33.         // line 2
  34.         $context["breadcrumbs"] = $this->extensions['VisualMedia\BreadcrumbBundle\Twig\TwigBreadcrumb']->breadcrumb((((isset($context["name"]) || array_key_exists("name"$context))) ? (_twig_default_filter((isset($context["name"]) || array_key_exists("name"$context) ? $context["name"] : (function () { throw new RuntimeError('Variable "name" does not exist.'2$this->source); })()), "Menu")) : ("Menu")), (((isset($context["options"]) || array_key_exists("options"$context))) ? (_twig_default_filter((isset($context["options"]) || array_key_exists("options"$context) ? $context["options"] : (function () { throw new RuntimeError('Variable "options" does not exist.'2$this->source); })()), [])) : ([])));
  35.         // line 3
  36.         echo "
  37. <div class=\"breadcrumb-nav\">
  38.     <ol itemscope itemtype=\"http://schema.org/BreadcrumbList\" class=\"breadcrumb\">
  39.         <li itemprop=\"itemListElement\" itemscope itemtype=\"http://schema.org/ListItem\">
  40.             <a itemprop=\"item\" href=\"";
  41.         // line 7
  42.         echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("home");
  43.         echo "\">
  44.                 <span itemprop=\"name\">Home</span>
  45.             </a>
  46.             <meta itemprop=\"position\" content=\"1\" />
  47.             <i class=\"fas fa-arrow-right\"></i>
  48.         </li>
  49.         ";
  50.         // line 15
  51.         echo "        ";
  52.         $context["position"] = 2;
  53.         // line 16
  54.         echo "        ";
  55.         $context['_parent'] = $context;
  56.         $context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env$this->source, (isset($context["breadcrumbs"]) || array_key_exists("breadcrumbs"$context) ? $context["breadcrumbs"] : (function () { throw new RuntimeError('Variable "breadcrumbs" does not exist.'16$this->source); })()), "paths", [], "any"falsefalsefalse16));
  57.         $context['loop'] = [
  58.           'parent' => $context['_parent'],
  59.           'index0' => 0,
  60.           'index'  => 1,
  61.           'first'  => true,
  62.         ];
  63.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  64.             $length count($context['_seq']);
  65.             $context['loop']['revindex0'] = $length 1;
  66.             $context['loop']['revindex'] = $length;
  67.             $context['loop']['length'] = $length;
  68.             $context['loop']['last'] = === $length;
  69.         }
  70.         foreach ($context['_seq'] as $context["_key"] => $context["breadcrumb"]) {
  71.             // line 17
  72.             echo "            ";
  73.             if (twig_get_attribute($this->env$this->source$context["loop"], "last", [], "any"falsefalsefalse17)) {
  74.                 // line 18
  75.                 echo "                <li itemprop=\"itemListElement\" itemscope itemtype=\"http://schema.org/ListItem\">
  76.                     <span itemprop=\"name\">";
  77.                 // line 19
  78.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["breadcrumb"], "title", [], "any"falsefalsefalse19), "html"nulltrue);
  79.                 echo "</span>
  80.                     <meta itemprop=\"position\" content=\"";
  81.                 // line 20
  82.                 echo twig_escape_filter($this->env, (isset($context["position"]) || array_key_exists("position"$context) ? $context["position"] : (function () { throw new RuntimeError('Variable "position" does not exist.'20$this->source); })()), "html"nulltrue);
  83.                 echo "\" />
  84.                 </li>
  85.             ";
  86.             } else {
  87.                 // line 24
  88.                 echo "                <li itemprop=\"itemListElement\" itemscope itemtype=\"http://schema.org/ListItem\">
  89.                     <a itemprop=\"item\" href=\"";
  90.                 // line 25
  91.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["breadcrumb"], "link", [], "any"falsefalsefalse25), "html"nulltrue);
  92.                 echo "\">
  93.                         <span itemprop=\"name\">";
  94.                 // line 26
  95.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["breadcrumb"], "title", [], "any"falsefalsefalse26), "html"nulltrue);
  96.                 echo "</span>
  97.                     </a>
  98.                     <meta itemprop=\"position\" content=\"";
  99.                 // line 28
  100.                 echo twig_escape_filter($this->env, (isset($context["position"]) || array_key_exists("position"$context) ? $context["position"] : (function () { throw new RuntimeError('Variable "position" does not exist.'28$this->source); })()), "html"nulltrue);
  101.                 echo "\" />
  102.                     <i class=\"fas fa-arrow-right\"></i>
  103.                 </li>
  104.             ";
  105.             }
  106.             // line 32
  107.             echo "            ";
  108.             $context["position"] = ((isset($context["position"]) || array_key_exists("position"$context) ? $context["position"] : (function () { throw new RuntimeError('Variable "position" does not exist.'32$this->source); })()) + 1);
  109.             // line 33
  110.             echo "        ";
  111.             ++$context['loop']['index0'];
  112.             ++$context['loop']['index'];
  113.             $context['loop']['first'] = false;
  114.             if (isset($context['loop']['length'])) {
  115.                 --$context['loop']['revindex0'];
  116.                 --$context['loop']['revindex'];
  117.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  118.             }
  119.         }
  120.         $_parent $context['_parent'];
  121.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['breadcrumb'], $context['_parent'], $context['loop']);
  122.         $context array_intersect_key($context$_parent) + $_parent;
  123.         // line 34
  124.         echo "    </ol>
  125. </div>
  126. ";
  127.         
  128.         $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
  129.         
  130.         $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
  131.     }
  132.     public function getTemplateName()
  133.     {
  134.         return "@VisualMediaBreadcrumb/Breadcrumb/breadcrumb.html.twig";
  135.     }
  136.     public function isTraitable()
  137.     {
  138.         return false;
  139.     }
  140.     public function getDebugInfo()
  141.     {
  142.         return array (  135 => 34,  121 => 33,  118 => 32,  111 => 28,  106 => 26,  102 => 25,  99 => 24,  92 => 20,  88 => 19,  85 => 18,  82 => 17,  64 => 16,  61 => 15,  51 => 7,  45 => 3,  43 => 2,);
  143.     }
  144.     public function getSourceContext()
  145.     {
  146.         return new Source("{# http://schema.org/BreadcrumbList #}
  147. {% set breadcrumbs = breadcrumb(name|default('Menu'), options|default({})) %}
  148. <div class=\"breadcrumb-nav\">
  149.     <ol itemscope itemtype=\"http://schema.org/BreadcrumbList\" class=\"breadcrumb\">
  150.         <li itemprop=\"itemListElement\" itemscope itemtype=\"http://schema.org/ListItem\">
  151.             <a itemprop=\"item\" href=\"{{ path('home') }}\">
  152.                 <span itemprop=\"name\">Home</span>
  153.             </a>
  154.             <meta itemprop=\"position\" content=\"1\" />
  155.             <i class=\"fas fa-arrow-right\"></i>
  156.         </li>
  157.         {# breadcrumb itemprop position, starts at 2, 1 is homepage #}
  158.         {% set position = 2 %}
  159.         {% for breadcrumb in breadcrumbs.paths %}
  160.             {% if loop.last %}
  161.                 <li itemprop=\"itemListElement\" itemscope itemtype=\"http://schema.org/ListItem\">
  162.                     <span itemprop=\"name\">{{ breadcrumb.title }}</span>
  163.                     <meta itemprop=\"position\" content=\"{{ position }}\" />
  164.                 </li>
  165.             {% else %}
  166.                 <li itemprop=\"itemListElement\" itemscope itemtype=\"http://schema.org/ListItem\">
  167.                     <a itemprop=\"item\" href=\"{{ breadcrumb.link }}\">
  168.                         <span itemprop=\"name\">{{ breadcrumb.title }}</span>
  169.                     </a>
  170.                     <meta itemprop=\"position\" content=\"{{ position }}\" />
  171.                     <i class=\"fas fa-arrow-right\"></i>
  172.                 </li>
  173.             {% endif %}
  174.             {% set position = position + 1 %}
  175.         {% endfor %}
  176.     </ol>
  177. </div>
  178. ""@VisualMediaBreadcrumb/Breadcrumb/breadcrumb.html.twig""/var/www/vhosts/localhost/html/templates/VisualMediaBreadcrumbBundle/views/Breadcrumb/breadcrumb.html.twig");
  179.     }
  180. }