app/template/syntpl/Module/breadcrumb.twig line 1

Open in your IDE?
  1. {% set product_list_title = '車検一覧' %}
  2. {% set itemprop_position = 0 %}
  3. {% if Page.url != 'homepage' %}
  4.     <div class="breadcrumb">
  5.         <div class="breadcrumb-inner">
  6.             <ul itemscope itemtype="https://schema.org/BreadcrumbList">
  7.                 <li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem">
  8.                     {% set itemprop_position = itemprop_position + 1 %}
  9.                     <meta itemprop="position" content="{{ itemprop_position}}" />
  10.                     <a itemprop="item" href="{{ url('homepage') }}">
  11.                         <span itemprop="name">ホーム</span>
  12.                     </a>
  13.                 </li>
  14.                 {% if
  15.                     (Page.url == 'product_list' and (search_form.vars.value.category_id or search_form.vars.value.name))
  16.                     or Page.url == 'product_detail'
  17.                 %}
  18.                     <li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem">
  19.                         {% set itemprop_position = itemprop_position + 1 %}
  20.                         <meta itemprop="position" content="{{ itemprop_position}}" />
  21.                         <a itemprop="item" href="{{ url('homepage') }}products/list">
  22.                             <span itemprop="name">{{ product_list_title }}</span>
  23.                         </a>
  24.                     </li>
  25.                     {% if Page.url == 'product_list' and Category is not null %}
  26.                         {% for Path in Category.path %}
  27.                             {% if loop.last == false %}
  28.                                 <li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem">
  29.                                     {% set itemprop_position = itemprop_position + 1 %}
  30.                                     <meta itemprop="position" content="{{ itemprop_position}}" />
  31.                                     <a itemprop="item" href="{{ url('product_list') }}?category_id={{ Path.id }}">
  32.                                         <span itemprop="name">{{ Path.name }}</span>
  33.                                     </a>
  34.                                 </li>
  35.                             {% endif %}
  36.                         {% endfor %}
  37.                     {% endif %}
  38.                 {% elseif 'shopping' in Page.url %}
  39.                     <li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem">
  40.                         {% set itemprop_position = itemprop_position + 1 %}
  41.                         <meta itemprop="position" content="{{ itemprop_position}}" />
  42.                         <a itemprop="item" href="{{ url('homepage') }}cart">
  43.                             <span itemprop="name">現在のカゴの中</span>
  44.                         </a>
  45.                     </li>
  46.                 {% elseif 'mypage' in Page.url %}
  47.                     <li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem">
  48.                         {% set itemprop_position = itemprop_position + 1 %}
  49.                         <meta itemprop="position" content="{{ itemprop_position}}" />
  50.                         <a itemprop="item" href="{{ url('homepage') }}mypage/">
  51.                             <span itemprop="name">MYページ</span>
  52.                         </a>
  53.                     </li>
  54.                 {% endif %}
  55.                 <li itemprop="itemListElement" itemscope itemtype="https://schema.org/ListItem">
  56.                     {% set itemprop_position = itemprop_position + 1 %}
  57.                     <meta itemprop="position" content="{{ itemprop_position}}" />
  58.                     <span itemprop="name">
  59.                         {% if Page.url == 'product_list' and search_form.vars.value and search_form.vars.value.name %}
  60.                             {{ '「%name%」の検索結果'|trans({ '%name%': search_form.vars.value.name }) }}
  61.                         {% elseif Page.url == 'product_list' and Category is null %}
  62.                             {{ product_list_title }}
  63.                         {% elseif Synplgblog is defined and Page.url == 'post_list' %}
  64.                             {{ Synplgblog.name }}
  65.                         {% elseif subtitle is defined and subtitle is not empty %}
  66.                             {{ subtitle }}
  67.                         {% elseif title is defined and title is not empty %}
  68.                             {{ title }}
  69.                         {% endif %}
  70.                     </span>
  71.                 </li>
  72.             </ul>
  73.         </div>
  74.     </div>
  75. {% endif %}