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

Open in your IDE?
  1. {% sw_extends '@parent/storefront/layout/meta.html.twig' %}
  2. {% block layout_head_inner %}{% apply spaceless %}
  3.     {% set metaInformation = page.metaInformation %}
  4.     {% set basicConfig = config("core").basicInformation %}
  5.     {% set items = page.header.navigation.tree %}
  6.     {% set activecategory = null %}
  7.     {% for item in items %}
  8.         {% if activecategory == null and item.category.id == page.header.navigation.active.id %}
  9.             {% set activecategory = item %}
  10.         {% else %}
  11.             {% if  activecategory == null %}
  12.                 {% set children = item.children %}
  13.                 {% for child in children %}
  14.                     {% if  activecategory == null and child.category.id == page.header.navigation.active.id %}
  15.                         {% set activecategory = child %}
  16.                     {% else %}
  17.                         {% if  activecategory == null %}
  18.                             {% set subchildren = child.children %}
  19.                             {% for subchild in subchildren %}
  20.                                 {% if  activecategory == null and subchild.category.id == page.header.navigation.active.id %}
  21.                                     {% set activecategory = subchild %}
  22.                                 {% else %}
  23.                                     {% set subsubchildren = subchild.children %}
  24.                                     {% for subsubchild in subsubchildren %}
  25.                                         {% if  activecategory == null and subsubchild.category.id == page.header.navigation.active.id %}
  26.                                             {% set activecategory = subsubchild %}
  27.                                         {% else %}
  28.                                             {% set subsubsubchildren = subsubchild.children %}
  29.                                             {% for subsubsubchild in subsubsubchildren %}
  30.                                                 {% if  activecategory == null and subsubsubchild.category.id == page.header.navigation.active.id %}
  31.                                                     {% set activecategory = subsubsubchild %}
  32.                                                 {% else %}
  33.                                                     {% set lastlevelchildren = subsubsubchild.children %}                                                    
  34.                                                     {% for lastlevelchild in lastlevelchildren %}
  35.                                                         {% if  activecategory == null and lastlevelchild.category.id == page.header.navigation.active.id %}
  36.                                                             {% set activecategory = lastlevelchild %}
  37.                                                         {% endif %}
  38.                                                     {% endfor %}
  39.                                                 {% endif %}
  40.                                             {% endfor %}
  41.                                         {% endif %}
  42.                                     {% endfor %}
  43.                                 {% endif %}
  44.                             {% endfor %}
  45.                         {% endif %}
  46.                     {% endif %}
  47.                 {% endfor %}
  48.             {% endif %}
  49.         {% endif %}
  50.     {% endfor %}
  51.     {% if page.product.translated.name|length > 0 %}    
  52.         {% set metaDescription = page.product.translated.name %}
  53.         {% set metaDescriptionComma = false %}
  54.         {% if page.product.customFields.custom_produkt_produkt_jahrgang %}
  55.             {% set metaDescription = metaDescription ~ ' ' ~ page.product.customFields.custom_produkt_produkt_jahrgang %}
  56.             {% set metaDescriptionComma = true %}
  57.         {% endif %}
  58.         {% if page.product.customFields.custom_produkt_produkt_lage %}
  59.             {% if metaDescriptionComma == true %}
  60.                 {% set metaDescription = metaDescription ~ ', ' %}
  61.             {% endif %}
  62.             {% set metaDescription = metaDescription ~ ' ' ~ page.product.customFields.custom_produkt_produkt_lage %}
  63.             {% set metaDescriptionComma = true %}
  64.         {% endif %}
  65.         {% if page.product.customFields.custom_produkt_produkt_typ %}
  66.             {% if metaDescriptionComma == true %}
  67.                 {% set metaDescription = metaDescription ~ ', ' %}
  68.             {% endif %}
  69.             {% set metaDescription = metaDescription ~ ' ' ~ page.product.customFields.custom_produkt_produkt_typ %}
  70.             {% set metaDescriptionComma = true %}
  71.         {% endif %}
  72.         {% if page.product.customFields.custom_produkt_produkt_flaschengroesse %}
  73.             {% if metaDescriptionComma == true %}
  74.                 {% set metaDescription = metaDescription ~ ', ' %}
  75.             {% endif %}
  76.             {% set metaDescription = metaDescription ~ ' ' ~ page.product.customFields.custom_produkt_produkt_flaschengroesse %}
  77.             {% set metaDescriptionComma = true %}
  78.         {% endif %}
  79.         {% if page.product.customFields.custom_produzent_produzent_name %}
  80.             {% if metaDescriptionComma == true %}
  81.                 {% set metaDescription = metaDescription ~ ', ' %}
  82.             {% endif %}
  83.             {% set metaDescription = metaDescription ~ ' ' ~ page.product.customFields.custom_produzent_produzent_name %}
  84.             {% set metaDescriptionComma = true %}
  85.         {% endif %}
  86.         {% if page.product.customFields.custom_weingut_produzent_region %}
  87.             {% if metaDescriptionComma == true %}
  88.                 {% set metaDescription = metaDescription ~ ', ' %}
  89.             {% endif %}
  90.             {% set metaDescription = metaDescription ~ ' ' ~ page.product.customFields.custom_weingut_produzent_region %}
  91.         {% endif %}
  92.         {% set metaDescription = metaDescription ~ '. ' %}
  93.         {% if page.product.customFields.custom_produkt_produkt_traubenbeschreibung %}
  94.             {% set metaDescription = metaDescription ~ 'product.metaDescriptionTraubensorten'|trans ~ ' ' ~ page.product.customFields.custom_produkt_produkt_traubenbeschreibung %}
  95.         {% endif %}
  96.         {% set metaDescription = metaDescription ~ ' ' ~ 'product.metaDescriptionSuffix'|trans %}
  97.     {% elseif (context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_producers in activecategory.category.path or context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_producers == activecategory.category.id) %}
  98.         {# Winzerportraits #}
  99.         {% if (activecategory.category.customFields.custom_category_attributes_land == true) %}
  100.             {% set metaDescription = 'producer.metaTitleProducerAffix'|trans ~ ' ' ~ activecategory.category.translated.name ~ ' | ' ~ 'product.metaDescriptionSuffixAlt'|trans ~ ' | ' ~ 'product.metaTitleMartelOnline'|trans %}
  101.         {% elseif (activecategory.category.customFields.custom_category_attributes_region == true) %}
  102.             {% set metaDescription = 'producer.metaTitleProducerAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name ~ ' / ' ~ activecategory.category.translated.name ~ ' | ' ~ 'product.metaDescriptionSuffixAlt'|trans ~ ' | ' ~ 'product.metaTitleMartelOnline'|trans %}
  103.         {% elseif (activecategory.category.customFields.custom_category_attributes_subregion == true) %}
  104.             {% set metaDescription = 'producer.metaTitleProducerAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_region_name ~ ' / ' ~ activecategory.category.translated.name ~ ' | ' ~ 'product.metaDescriptionSuffixAlt'|trans ~ ' | ' ~ 'product.metaTitleMartelOnline'|trans %}
  105.         {% elseif (activecategory.category.customFields.custom_category_attributes_weingut == true) %}
  106.             {% set metaDescription = 'producer.metaTitleProducerAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name %}
  107.             {% if activecategory.category.translated.customFields.custom_category_attributes_region_name %}
  108.                 {% set metaDescription = metaDescription ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_region_name %}
  109.             {% endif %}
  110.             {% if activecategory.category.translated.customFields.custom_category_attributes_subregion_name %}
  111.                 {% set metaDescription = metaDescription ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_subregion_name %}
  112.             {% endif %}
  113.             {% set metaDescription = metaDescription ~ ' / ' ~ activecategory.category.translated.name ~ ' | ' ~ 'product.metaDescriptionSuffixAlt'|trans ~ ' | ' ~ 'product.metaTitleMartelOnline'|trans %}
  114.         {% else %}
  115.             {% set metaDescription = metaInformation.metaDescription|striptags|trim|u.truncate(config("seo").seo.descriptionMaxLength ?? 160, '…') %}
  116.         {% endif %}
  117.         
  118.     {% elseif (context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_regions in activecategory.category.path or context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_regions == activecategory.category.id) %}
  119.         {# Weinregionen #}
  120.         {% if (activecategory.category.customFields.custom_category_attributes_land == true) %}
  121.             {% set metaDescription = 'producer.metaTitleProducerRegionAffix'|trans ~ ' ' ~ activecategory.category.translated.name ~ ' | ' ~ 'product.metaDescriptionSuffixAlt'|trans ~ ' | ' ~ 'product.metaTitleMartelOnline'|trans %}
  122.         {% elseif (activecategory.category.customFields.custom_category_attributes_region == true) %}
  123.             {% set metaDescription = 'producer.metaTitleProducerRegionAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name ~ ' / ' ~ activecategory.category.translated.name ~ ' | ' ~ 'product.metaDescriptionSuffixAlt'|trans ~ ' | ' ~ 'product.metaTitleMartelOnline'|trans %}
  124.         {% elseif (activecategory.category.customFields.custom_category_attributes_subregion == true) %}
  125.             {% set metaDescription = 'producer.metaTitleProducerRegionAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_region_name ~ ' / ' ~ activecategory.category.translated.name ~ ' | ' ~ 'product.metaDescriptionSuffixAlt'|trans ~ ' | ' ~ 'product.metaTitleMartelOnline'|trans %}
  126.         {% elseif (activecategory.category.customFields.custom_category_attributes_weingut == true) %}
  127.             {% set metaDescription = 'producer.metaTitleProducerAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name %}
  128.             {% if activecategory.category.translated.customFields.custom_category_attributes_region_name %}
  129.                 {% set metaDescription = metaDescription ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_region_name %}
  130.             {% endif %}
  131.             {% if activecategory.category.translated.customFields.custom_category_attributes_subregion_name %}
  132.                 {% set metaDescription = metaDescription ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_subregion_name %}
  133.             {% endif %}
  134.             {% set metaDescription = metaDescription ~ ' / ' ~ activecategory.category.translated.name ~ ' | ' ~ 'product.metaDescriptionSuffixAlt'|trans ~ ' | ' ~ 'product.metaTitleMartelOnline'|trans %}
  135.         {% else %}
  136.             {% set metaDescription = metaInformation.metaDescription|striptags|trim|u.truncate(config("seo").seo.descriptionMaxLength ?? 160, '…') %}
  137.         {% endif %}
  138.     {% else %}
  139.         {% set metaDescription = metaInformation.metaDescription|striptags|trim|u.truncate(config("seo").seo.descriptionMaxLength ?? 160, '…') %}
  140.     {% endif %}  
  141.     {% if page.product.translated.name|length > 0 %}
  142.         {% set metaTitleComma = false %}
  143.         {% set metaTitle = page.product.translated.name %}
  144.         {% if page.product.customFields.custom_produkt_produkt_jahrgang %}
  145.             {% set metaTitle = metaTitle ~ ' ' ~ page.product.customFields.custom_produkt_produkt_jahrgang %}
  146.             {% set metaTitleComma = true %}
  147.         {% endif %}
  148.         {% if page.product.customFields.custom_produkt_produkt_flaschengroesse %}
  149.             {% if metaTitleComma == true %}
  150.                 {% set metaTitle = metaTitle ~ ', ' %}
  151.             {% endif %}
  152.             {% set metaTitle = metaTitle ~ ' ' ~ page.product.customFields.custom_produkt_produkt_flaschengroesse %}
  153.             {% set metaTitleComma = true %}
  154.         {% endif %}
  155.         {% if page.product.customFields.custom_produzent_produzent_name %}
  156.             {% if metaTitleComma == true %}
  157.                 {% set metaTitle = metaTitle ~ ' - ' %}
  158.                 {% set metaTitle = metaTitle ~ ' ' ~ page.product.customFields.custom_produzent_produzent_name %}
  159.                 {% set metaTitleComma = true %}
  160.             {% endif %}
  161.         {% endif %}
  162.         {% set metaTitle = metaTitle ~ ' | ' ~ 'product.metaTitleSuffix'|trans %}
  163.     {% elseif (context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_producers in activecategory.category.path or context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_producers == activecategory.category.id) %}
  164.         {# Winzerportraits #}
  165.         {% if (activecategory.category.customFields.custom_category_attributes_land == true) %}
  166.             {% set metaTitle = 'producer.metaTitleProducerAffix'|trans ~ ' ' ~ activecategory.category.translated.name %}
  167.         {% elseif (activecategory.category.customFields.custom_category_attributes_region == true) %}
  168.             {% set metaTitle = 'producer.metaTitleProducerAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name ~ ' / ' ~ activecategory.category.translated.name %}
  169.         {% elseif (activecategory.category.customFields.custom_category_attributes_subregion == true) %}
  170.             {% set metaTitle = 'producer.metaTitleProducerAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_region_name ~ ' / ' ~ activecategory.category.translated.name %}
  171.         {% elseif (activecategory.category.customFields.custom_category_attributes_weingut == true) %}
  172.             {% set metaTitle = 'producer.metaTitleProducerAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name %}
  173.             {% if activecategory.category.translated.customFields.custom_category_attributes_region_name %}
  174.                 {% set metaTitle = metaTitle ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_region_name %}
  175.             {% endif %}
  176.             {% if activecategory.category.translated.customFields.custom_category_attributes_subregion_name %}
  177.                 {% set metaTitle = metaTitle ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_subregion_name %}
  178.             {% endif %}
  179.             {% set metaTitle = metaTitle ~ ' / ' ~ activecategory.category.translated.name %}
  180.         {% else %}
  181.             {% set metaTitle = metaInformation.metaTitle|striptags|trim %}
  182.         {% endif %}
  183.     {% elseif (context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_regions in activecategory.category.path or context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_regions == activecategory.category.id) %}
  184.         {# Weinregionen #}
  185.         {% if (activecategory.category.customFields.custom_category_attributes_land == true) %}
  186.             {% set metaTitle = 'producer.metaTitleProducerRegionAffix'|trans ~ ' ' ~ activecategory.category.translated.name %}
  187.         {% elseif (activecategory.category.customFields.custom_category_attributes_region == true) %}
  188.             {% set metaTitle = 'producer.metaTitleProducerRegionAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name ~ ' / ' ~ activecategory.category.translated.name %}
  189.         {% elseif (activecategory.category.customFields.custom_category_attributes_subregion == true) %}
  190.             {% set metaTitle = 'producer.metaTitleProducerRegionAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_region_name ~ ' / ' ~ activecategory.category.translated.name %}
  191.         {% elseif (activecategory.category.customFields.custom_category_attributes_weingut == true) %}
  192.             {% set metaTitle = 'producer.metaTitleProducerAffix'|trans ~ ' ' ~ activecategory.category.translated.customFields.custom_category_attributes_land_name %}
  193.             {% if activecategory.category.translated.customFields.custom_category_attributes_region_name %}
  194.                 {% set metaTitle = metaTitle ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_region_name %}
  195.             {% endif %}
  196.             {% if activecategory.category.translated.customFields.custom_category_attributes_subregion_name %}
  197.                 {% set metaTitle = metaTitle ~ ' / ' ~ activecategory.category.translated.customFields.custom_category_attributes_subregion_name %}
  198.             {% endif %}
  199.             {% set metaTitle = metaTitle ~ ' / ' ~ activecategory.category.translated.name %}
  200.         {% else %}
  201.             {% set metaTitle = metaInformation.metaTitle|striptags|trim %}
  202.         {% endif %}
  203.     {% else %}
  204.         {% set metaTitle = metaInformation.metaTitle|striptags|trim %}
  205.         {% if metaTitle == "Martel AG" %}
  206.             {% set metaTitle = "general.weinhandlungMartel"|trans %}
  207.         {% endif %}
  208.     {% endif %}
  209.     {% if page.product.translated.name|length > 0 %}
  210.         {% set metaKeywords = page.product.translated.name %}
  211.     {% else %}
  212.         {% set metaKeywords = metaInformation.metaKeywords|striptags|trim %}
  213.     {% endif %}
  214. {% endapply %}<head>    
  215.         {% block layout_head_meta_tags %}
  216.             {% block layout_head_meta_tags_charset %}
  217.                 <meta charset="utf-8">
  218.                 <link rel="preconnect" href="//app.usercentrics.eu">
  219.                 <link rel="preconnect" href="//api.usercentrics.eu">
  220.                 <link rel="preconnect" href="//privacy-proxy.usercentrics.eu">
  221.                 <link rel="preload" href="//app.usercentrics.eu/browser-ui/latest/loader.js" as="script">
  222.                 <link rel="preload" href="//privacy-proxy.usercentrics.eu/latest/uc-block.bundle.js" as="script">
  223.                 <script id="usercentrics-cmp" src="https://app.usercentrics.eu/browser-ui/latest/loader.js" data-settings-id="rt7Kk_f6fzLC7Y" async></script>
  224.                 <script type="application/javascript" src="https://privacy-proxy.usercentrics.eu/latest/uc-block.bundle.js"></script>
  225.                 {% block wbm_layout_head_tag_manager_data_layer_push %}
  226.                     <script>
  227.                         let gtmIsTrackingProductClicks = Boolean({{ wbmTagManagerConfig.isTrackingProductClicks|raw }}), gtmContainerId = '{{ wbmTagManagerConfig.gtmContainerId|raw }}', hasSWConsentSupport = Boolean(Number({{ wbmTagManagerConfig.hasSWConsentSupport }}));
  228.                         window.wbmScriptIsSet = false;
  229.                     </script>
  230.                     {% if dataLayer %}<script {{ wbmTagManagerConfig.dataLayerScriptTagAttributes|raw }}>{% verbatim %}
  231.                         window.dataLayer = window.dataLayer || [];
  232.                         window.dataLayer.push({% endverbatim %}{{ dataLayer|raw }}{% verbatim %});
  233.                         {% endverbatim %}{% if onEvent %}{% verbatim %}
  234.                         var onEventDataLayer = JSON.parse('{% endverbatim %}{{ onEvent|raw }}{% verbatim %}');
  235.                         {% endverbatim %}{% endif %}
  236.                     </script>{% endif %}
  237.                 {% endblock %}
  238.                 {% block wbm_layout_head_tag_manager_snippet %}
  239.                     {% if wbmTagManagerConfig.gtmContainerId %}<!-- WbmTagManagerEcomm Head Snippet Start -->
  240.                         <script id="wbmTagManger" {{ wbmTagManagerConfig.scriptTagAttributes|raw }}>{% verbatim %}
  241.                             function getCookie(name) {
  242.                                 var cookieMatch = document.cookie.match(name + '=(.*?)(;|$)');
  243.                                 return cookieMatch && decodeURI(cookieMatch[1]);
  244.                             }
  245.                             var gtmCookieSet = getCookie('{% endverbatim %}{{ wbmTagManagerConfig.wbmCookieEnabledName }}{% verbatim %}');
  246.                             {% endverbatim %}{% if wbmTagManagerConfig.gtmFunctionOverwrite is empty %}{% verbatim %}
  247.                             var googleTag = function(w, d, s, l, i) {
  248.                                 w[l] = w[l] || [];
  249.                                 w[l].push({
  250.                                     'gtm.start': new Date().getTime(),
  251.                                     event: 'gtm.js'
  252.                                 });
  253.                                 var f = d.getElementsByTagName(s)[0],
  254.                                     j = d.createElement(s),
  255.                                     dl = l != 'dataLayer' ? '&l=' + l : '';
  256.                                 j.async = true;
  257.                                 j.src = 'https://www.googletagmanager.com/gtm.js?id=' + i + dl + 
  258.                                         '{% endverbatim %}{{ wbmTagManagerConfig.extendedUrlParameter|trim|raw }}{% verbatim %}';
  259.                                 j.setAttribute('data-usercentrics', 'Google Tag Manager'); // Set data-usercentrics attribute
  260.                                 j.setAttribute('type', 'text/plain'); // Set type attribute
  261.                                 f.parentNode.insertBefore(j, f);
  262.                             };
  263.                             {% endverbatim %}{% else %}{% verbatim %}
  264.                             var googleTag = {% endverbatim %}{{ wbmTagManagerConfig.gtmFunctionOverwrite }}{% verbatim %}
  265.                             {% endverbatim %}{% endif %}{% verbatim %}
  266.                             if (hasSWConsentSupport && gtmCookieSet === null) {
  267.                                 window.wbmGoogleTagmanagerId = gtmContainerId;
  268.                                 window.wbmScriptIsSet = false;
  269.                                 window.googleTag = googleTag;
  270.                             } else {
  271.                                 window.wbmScriptIsSet = true;
  272.                                 googleTag(window, document, 'script', 'dataLayer', gtmContainerId);
  273.                                 googleTag = null;
  274.                             }{% endverbatim %}
  275.                         </script><!-- WbmTagManagerEcomm Head Snippet End -->{% endif %}
  276.                 {% endblock %}
  277.                 
  278.                 {# {% block nextag_martel_ga4_snippet %}
  279.                     <script async src="https://www.googletagmanager.com/gtag/js?id=G-Q50RHQ2K9D"></script>
  280.                     <script>
  281.                     window.dataLayer = window.dataLayer || [];
  282.                     function gtag(){dataLayer.push(arguments);}
  283.                     gtag('js', new Date());
  284.                     gtag('config', 'G-Q50RHQ2K9D');
  285.                     </script>
  286.                 {% endblock %} #}
  287.                 {% block nextag_hotjar_snippet %}
  288.                     {% if "martel.ch" in app.request.uri %}
  289.                         <!-- Hotjar Tracking Code for https://www.martel.ch -->
  290.                         <script type="text/plain" data-usercentrics="Hotjar">
  291.                             (function(h,o,t,j,a,r){
  292.                                 h.hj=h.hj||function(){(h.hj.q=h.hj.q||[]).push(arguments)};
  293.                                 h._hjSettings={hjid:3046135,hjsv:6};
  294.                                 a=o.getElementsByTagName('head')[0];
  295.                                 r=o.createElement('script');r.async=1;
  296.                                 r.src=t+h._hjSettings.hjid+j+h._hjSettings.hjsv;
  297.                                 a.appendChild(r);
  298.                             })(window,document,'https://static.hotjar.com/c/hotjar-','.js?sv=');
  299.                         </script>
  300.                         <meta name="p:domain_verify" content="df71b587b62c0e263841589e5a864963"/>
  301.                         <!-- Meta Pixel Code -->
  302.                         <script type="text/plain" data-usercentrics="Facebook Pixel">
  303.                         !function(f,b,e,v,n,t,s)
  304.                         {if(f.fbq)return;n=f.fbq=function(){n.callMethod?
  305.                         n.callMethod.apply(n,arguments):n.queue.push(arguments)};
  306.                         if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';
  307.                         n.queue=[];t=b.createElement(e);t.async=!0;
  308.                         t.src=v;s=b.getElementsByTagName(e)[0];
  309.                         s.parentNode.insertBefore(t,s)}(window, document,'script',
  310.                         'https://connect.facebook.net/en_US/fbevents.js');
  311.                         fbq('init', '1387008084961365');
  312.                         fbq('track', 'PageView');
  313.                         </script>
  314.                         <!-- End Meta Pixel Code -->
  315.                     {% endif %}
  316.                 {% endblock %}
  317.             {% endblock %}
  318.             {% block layout_head_meta_tags_viewport %}
  319.                 <meta name="viewport"
  320.                       content="width=device-width, initial-scale=1, shrink-to-fit=no">
  321.             {% endblock %}
  322.             {% block layout_head_meta_tags_general %}
  323.                 <meta name="author"
  324.                       content="{{ "general.martelWeinwelt"|trans }}"/>
  325.                 <meta name="publisher"
  326.                       content="{{ "general.martelWeinwelt"|trans }}"/>                   
  327.                 {% if "LP-Vorlage MEX" in page.cmsPage.translated.name or "LP-Vorlage B2B-Aktion" in page.cmsPage.translated.name %}
  328.                     <meta name="robots" id="meta-robots" 
  329.                       content="noindex,nofollow"/>
  330.                 {% elseif page.cmsPage.translated.name == "Martel-Kategorie" %}
  331.                     <meta name="robots" id="meta-robots" 
  332.                       content="index,follow"/>
  333.                 {% else %}
  334.                     <meta name="robots" id="meta-robots" 
  335.                       content="{% block layout_head_meta_tags_robots %}{{ metaInformation.robots }}{% endblock %}"/>
  336.                 {% endif %}
  337.                 <meta name="revisit-after"
  338.                       content="{{ metaInformation.revisit|striptags }}"/>
  339.                 <meta name="keywords"
  340.                       content="{% block layout_head_meta_tags_keywords %}{{ metaKeywords }}{% endblock %}"/>
  341.                 <meta name="description"
  342.                       content="{% block layout_head_meta_tags_description %}{{ metaDescription }}{% endblock %}"/>
  343.                 <meta name="format-detection" content="telephone=no">
  344.             {% endblock %}
  345.             {% block layout_head_meta_tags_opengraph %}
  346.                 <meta property="og:type"
  347.                       content="website"/>
  348.                 <meta property="og:site_name"
  349.                       content="{{ basicConfig.shopName }}"/>
  350.                 <meta property="og:title"
  351.                       content="{{ metaTitle }}"/>
  352.                 <meta property="og:description"
  353.                       content="{% block layout_head_meta_tags_description_og %}{{ metaDescription }}{% endblock %}"/>
  354.                 <meta property="og:image"
  355.                       content="{{ theme_config('sw-logo-share') }}"/>
  356.                 <meta name="twitter:card"
  357.                       content="summary"/>
  358.                 <meta name="twitter:site"
  359.                       content="{{ basicConfig.shopName }}"/>
  360.                 <meta name="twitter:title"
  361.                       content="{{ metaTitle }}"/>
  362.                 <meta name="twitter:description"
  363.                       content="{% block layout_head_meta_tags_description_twitter %}{{ metaDescription }}{% endblock %}"/>
  364.                 <meta name="twitter:image"
  365.                       content="{{ theme_config('sw-logo-share') }}"/>
  366.             {% endblock %}
  367.             {% block layout_head_meta_tags_schema_webpage %}
  368.                 <meta itemprop="copyrightHolder"
  369.                       content="{{ basicConfig.shopName }}"/>
  370.                 <meta itemprop="copyrightYear"
  371.                       content="{{ metaInformation.copyrightYear|striptags }}"/>
  372.                 <meta itemprop="isFamilyFriendly"
  373.                       content="{% if basicConfig.familyFriendly %}true{% else %}false{% endif %}"/>
  374.                 <meta itemprop="image"
  375.                       content="{{ theme_config('sw-logo-desktop') }}"/>
  376.             {% endblock %}
  377.             {% block layout_head_meta_tags_hreflangs %}
  378.                 {% for link in hrefLang %}
  379.                     <link rel="alternate" hreflang="{{ link.locale }}" href="{{ link.url }}" />
  380.                 {% endfor %}
  381.             {% endblock %}
  382.         {% endblock %}
  383.         {% block layout_head_favicon %}
  384.             <link rel="apple-touch-icon" sizes="180x180" href="/bundles/nextagtheme/assets/favicons/apple-touch-icon.png">
  385.             <link rel="icon" type="image/png" sizes="32x32" href="/bundles/nextagtheme/assets/favicons/favicon-32x32.png">
  386.             <link rel="icon" type="image/png" sizes="16x16" href="/bundles/nextagtheme/assets/favicons/favicon-16x16.png">
  387.             <link rel="manifest" href="/bundles/nextagtheme/assets/favicons/site.webmanifest">
  388.             <link rel="shortcut icon" href="/bundles/nextagtheme/assets/favicons/favicon.ico">
  389.             <meta name="msapplication-TileColor" content="#000000">
  390.             <meta name="msapplication-config" content="/bundles/nextagtheme/assets/favicons/browserconfig.xml">
  391.             <meta name="theme-color" content="#ffffff">
  392.         {% endblock %}
  393.         {% block layout_head_apple %}
  394.         {% endblock %}
  395.         {% block layout_head_android %}
  396.         {% endblock %}
  397.         {% block layout_head_canonical %}
  398.             {% if page.metaInformation.canonical %}
  399.                 {% if page.cmsPage.translated.name == "Martel-Kategorie" %}
  400.                 {% if (app.request.locale == "en-GB") %}
  401.                     <link rel="canonical" href="{{app.request.get('sw-sales-channel-absolute-base-url')}}/en/wine/"/>
  402.                 {% elseif(app.request.locale == "fr-FR") %}
  403.                     <link rel="canonical" href="{{app.request.get('sw-sales-channel-absolute-base-url')}}/fr/vin/"/>
  404.                 {%  else %}                    
  405.                     <link rel="canonical" href="{{app.request.get('sw-sales-channel-absolute-base-url')}}/wein/"/>
  406.                 {%  endif %}
  407.                 {% else %}
  408.                     <link rel="canonical" href="{{ page.metaInformation.canonical }}" />
  409.                 {% endif %}        
  410.             {% endif %}
  411.         {% endblock %}
  412.         {% block layout_head_title %}
  413.             <title itemprop="name" id="itempropname">
  414.                 {% block layout_head_title_inner %}{% apply spaceless %}
  415.                     {{ metaTitle }}
  416.                 {% endapply %}{% endblock %}
  417.             </title>
  418.         {% endblock %}
  419.         {% block layout_head_stylesheet %}
  420.             {% if context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_regions in activecategory.category.path or 
  421.                 context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_regions == activecategory.category.id or
  422.                 context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_producers in activecategory.category.path or 
  423.                 context.salesChannel.translated.customFields.custom_winzerportraits_weinregionen_cat_producers == activecategory.category.id 
  424.             %}
  425.                 <link rel="stylesheet" href="/cms/wp-content/themes/next-theme/assets/lib/swiper-6.4.14/swiper-bundle.min.css">
  426.             {% endif %}
  427.             {% if isHMRMode %}
  428.                 {# CSS will be loaded from the JS automatically #}
  429.             {% else %}
  430.                 {% set assets = theme_config('assets.css') %}
  431.                 {% for file in assets %}
  432.                     {# <link rel="preload" href="{{ asset(file, 'theme') }}" as="style" onload="this.onload=null;this.rel='stylesheet'">
  433.                     <noscript><link rel="stylesheet" href="{{ asset(file, 'theme') }}"></noscript> #}
  434.                     <link rel="stylesheet" href="{{ asset(file, 'theme') }}">
  435.                 {% endfor %}
  436.             {% endif %}
  437.         {% endblock %}
  438.         {% block layout_head_javascript_feature %}
  439.             {% sw_include "@Storefront/storefront/component/feature.html.twig" %}
  440.         {% endblock %}
  441.         {# Block for tracking scripts which are required to include in the `head` section of the document #}
  442.         {% block layout_head_javascript_tracking %}
  443.             {% sw_include "@Storefront/storefront/component/analytics.html.twig" %}
  444.             {# Google Tag Manager #}
  445.             {% if "martel.dev7" not in app.request.uri  %}
  446.                 <script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
  447.                 new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
  448.                 j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
  449.                 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
  450.                 })(window,document,'script','dataLayer','GTM-MQ8CCQC');</script>
  451.             {% endif %}
  452.         {% endblock %}
  453.         {% block layout_head_preconnect %}
  454.             <link rel="preconnect" href="https://www.google-analytics.com" crossorigin>
  455.             <link rel="preconnect" href="https://www.googletagmanager.com" crossorigin>
  456.         {% endblock %}
  457.         {% block layout_header_google_maps %}
  458.             
  459.         {% endblock %}
  460.     </head>
  461. {% endblock %}