custom/plugins/OttMoebelfirstTheme/src/Resources/views/storefront/layout/meta.html.twig line 1

Open in your IDE?
  1. {% sw_extends '@Storefront/storefront/layout/meta.html.twig' %}
  2. {% block layout_head_meta_tags_robots %}{% if page.extensions.ottMerchantShopsData %}noindex,follow{% else %}{{ parent() }}{% endif %}{% endblock %}
  3. {% block layout_head_meta_tags %}
  4.     {{ parent() }}
  5.     <link rel="preload"
  6.           as="font"
  7.           href="/bundles/ottmoebelfirsttheme/assets/fonts/Lora/Lora-Regular.ttf"
  8.           type="font/ttf"
  9.           crossorigin="anonymous">
  10.     <link rel="preload"
  11.           as="font"
  12.           href="/bundles/ottmoebelfirsttheme/assets/fonts/Poppins/Poppins-Regular.ttf"
  13.           type="font/ttf"
  14.           crossorigin="anonymous">
  15.     <link rel="preload"
  16.           as="font"
  17.           href="/bundles/ottmoebelfirsttheme/assets/fonts/Poppins/Poppins-Light.ttf"
  18.           type="font/ttf"
  19.           crossorigin="anonymous">
  20.     <link rel="preload"
  21.           as="font"
  22.           href="/bundles/ottmoebelfirsttheme/assets/fonts/Poppins/Poppins-Medium.ttf"
  23.           type="font/ttf"
  24.           crossorigin="anonymous">
  25.     <link rel="preload"
  26.           as="font"
  27.           href="/bundles/ottmoebelfirsttheme/assets/fonts/Poppins/Poppins-SemiBold.ttf"
  28.           type="font/ttf"
  29.           crossorigin="anonymous">
  30.     <link rel="preload"
  31.           as="font"
  32.           href="/bundles/ottmoebelfirsttheme/assets/fonts/Lora/Lora-Medium.ttf"
  33.           type="font/ttf"
  34.           crossorigin="anonymous">
  35.     <link rel="preload"
  36.           as="font"
  37.           href="/bundles/ottmoebelfirsttheme/assets/fonts/Lora/Lora-SemiBold.ttf"
  38.           type="font/ttf"
  39.           crossorigin="anonymous">
  40.     <link rel="preload"
  41.           as="font"
  42.           href="/bundles/ottmoebelfirsttheme/assets/fonts/Lora/Lora-Bold.ttf"
  43.           type="font/ttf"
  44.           crossorigin="anonymous">
  45. {% endblock %}
  46. {% block layout_head_canonical %}
  47.     {% if 'detail' === cbaxModulManufacturers.page %}
  48.         {% set parameters = '' %}
  49.         {% if app.request.query.get('p') and '1' !== app.request.query.get('p') %}
  50.             {% set parameters = '?p=' ~ app.request.query.get('p') %}
  51.         {% endif %}
  52.         <link rel="canonical"
  53.               href="{{ seoUrl('frontend.cbax.manufacturer.detail', { cbaxManufacturerId: cbaxModulManufacturers.manufacturer.id }) ~ parameters }}"
  54.         />
  55.     {% else %}
  56.         {{ parent() }}
  57.     {% endif %}
  58. {% endblock %}
  59. {% block layout_head_title_inner %}{% apply spaceless %}
  60.     {% set brandCategory = '24a08e1dd39a4574a51b3f5144ffb17c' %}
  61.     {% if page.landingpage %}
  62.         {% set categoryName = page.landingpage.category.translated.name|capitalize %}
  63.         {% set brandIndex = 1 %}
  64.         {% if '/' === page.landingpage.translated.title|first %}
  65.             {% set brandIndex = 2 %}
  66.         {% endif %}
  67.         {% set pathParts = page.landingpage.translated.title|split('/') %}
  68.         {% set brandName = pathParts[brandIndex]|replace({ '-': ' ' })|title %}
  69.         {{ 'ott.manufacturerSubCategory.metaTitle'|trans({
  70.             '%category%': categoryName,
  71.             '%brand%': brandName,
  72.         }) }}
  73.     {% elseif cbaxModulManufacturers %}
  74.         {% if cbaxModulManufacturers.page == "index" %}
  75.             {{ "cbaxManufacturer.page.index.allManufacturers"|trans }} | {{ metaTitle }}
  76.         {% else %}
  77.             {{ 'ott.manufacturerDetail.metaTitle'|trans({
  78.                 '%brand%': cbaxModulManufacturers.manufacturer.translated.name,
  79.             }) }}
  80.         {% endif %}
  81.     {% elseif brandCategory in page.header.navigation.active.path %}
  82.         {% set breadcrumbCategories = sw_breadcrumb_full(page.header.navigation.active, context.context) %}
  83.         {% set brandName = '' %}
  84.         {% if 3 === breadcrumbCategories|length and brandCategory === breadcrumbCategories|first.id|lower%}
  85.             {% for breadcrumbCategory in breadcrumbCategories %}
  86.                 {% if 1 === loop.index0 %}
  87.                     {% set brandName = breadcrumbCategory.translated.name %}
  88.                 {% endif %}
  89.             {% endfor %}
  90.         {% endif %}
  91.         {{ 'ott.manufacturerSubCategory.metaTitle'|trans({
  92.             '%category%': page.header.navigation.active.translated.name,
  93.             '%brand%': brandName,
  94.         }) }}
  95.     {% else %}
  96.         {{ parent() }}
  97.     {% endif %}
  98. {% endapply %}{% endblock %}
  99. {% block layout_head_meta_tags_description %}{% apply spaceless %}
  100.     {% set brandCategory = '24a08e1dd39a4574a51b3f5144ffb17c' %}
  101.     {% if page.landingpage %}
  102.         {% set categoryName = page.landingpage.category.translated.name|capitalize %}
  103.         {% set brandIndex = 1 %}
  104.         {% if '/' === page.landingpage.translated.title|first %}
  105.             {% set brandIndex = 2 %}
  106.         {% endif %}
  107.         {% set pathParts = page.landingpage.translated.title|split('/') %}
  108.         {% set brandName = pathParts[brandIndex]|replace({ '-': ' ' })|title %}
  109.         {{ 'ott.manufacturerSubCategory.metaDescription'|trans({
  110.             '%category%': categoryName,
  111.             '%brand%': brandName,
  112.         }) }}
  113.     {% elseif cbaxModulManufacturers %}
  114.         {% if cbaxModulManufacturers.page == "index" %}
  115.             {{ "cbaxManufacturer.page.index.metaDescription"|trans }}
  116.         {% else %}
  117.             {{ 'ott.manufacturerDetail.metaDescription'|trans({
  118.                 '%brand%': cbaxModulManufacturers.manufacturer.translated.name,
  119.             }) }}
  120.         {% endif %}
  121.     {% elseif brandCategory in page.header.navigation.active.path %}
  122.         {% set breadcrumbCategories = sw_breadcrumb_full(page.header.navigation.active, context.context) %}
  123.         {% set brandName = '' %}
  124.         {% if 3 === breadcrumbCategories|length and brandCategory === breadcrumbCategories|first.id|lower%}
  125.             {% for breadcrumbCategory in breadcrumbCategories %}
  126.                 {% if 1 === loop.index0 %}
  127.                     {% set brandName = breadcrumbCategory.translated.name %}
  128.                 {% endif %}
  129.             {% endfor %}
  130.         {% endif %}
  131.         {{ 'ott.manufacturerSubCategory.metaDescription'|trans({
  132.             '%category%': page.header.navigation.active.translated.name,
  133.             '%brand%': brandName,
  134.         }) }}
  135.     {% else %}
  136.         {{ parent() }}
  137.     {% endif %}
  138. {% endapply %}{% endblock %}
  139. {% block layout_head_meta_tags_description_og %}{% apply spaceless %}
  140.     {% if cbaxModulManufacturers %}
  141.         {% if cbaxModulManufacturers.page == "index" %}
  142.             {{ "cbaxManufacturer.page.index.metaDescription"|trans }}
  143.         {% else %}
  144.             {{ 'ott.manufacturerDetail.metaDescription'|trans({
  145.                 '%brand%': cbaxModulManufacturers.manufacturer.translated.name,
  146.             }) }}
  147.         {% endif %}
  148.     {% else %}
  149.         {{ parent() }}
  150.     {% endif %}
  151. {% endapply %}{% endblock %}
  152. {% block layout_head_meta_tags_description_twitter %}{% apply spaceless %}
  153.     {% if cbaxModulManufacturers %}
  154.         {% if cbaxModulManufacturers.page == "index" %}
  155.             {{ "cbaxManufacturer.page.index.metaDescription"|trans }}
  156.         {% else %}
  157.             {{ 'ott.manufacturerDetail.metaDescription'|trans({
  158.                 '%brand%': cbaxModulManufacturers.manufacturer.translated.name,
  159.             }) }}
  160.         {% endif %}
  161.     {% else %}
  162.         {{ parent() }}
  163.     {% endif %}
  164. {% endapply %}{% endblock %}