src/CoreBundle/Resources/views/Includes/headProducts.html.twig line 1

Open in your IDE?
  1. {% set productName = product.getName() %}
  2. {% if product.getShortTextRepresentation() is not empty %}
  3.     {% set productMetaDescription = product.getShortTextRepresentation() %}
  4. {% else %}
  5.     {% set productMetaDescription = product.getLongTextRepresentation() %}
  6. {% endif %}
  7. <head>
  8.     <meta charset="UTF-8">
  9.     <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
  10.     {% spaceless -%}
  11.         <!--
  12.                 /**
  13.                  * @license
  14.                  * MyFonts Webfont Build ID 3697904, 2019-01-14T14:44:27-0500
  15.                  *
  16.                  * The fonts listed in this notice are subject to the End User License
  17.                  * Agreement(s) entered into by the website owner. All other parties are
  18.                  * explicitly restricted from using the Licensed Webfonts(s).
  19.                  *
  20.                  * You may obtain a valid license at the URLs below.
  21.                  *
  22.                  * Webfont: FrutigerLTPro-Light by Linotype
  23.                  * URL: https://www.myfonts.com/fonts/linotype/frutiger/pro-45-light/
  24.                  *
  25.                  * Webfont: FrutigerLTPro-Roman by Linotype
  26.                  * URL: https://www.myfonts.com/fonts/linotype/frutiger/pro-55-roman-2/
  27.                  *
  28.                  * Webfont: FrutigerLTPro-Bold by Linotype
  29.                  * URL: https://www.myfonts.com/fonts/linotype/frutiger/pro-65-bold-2/
  30.                  *
  31.                  *
  32.                  * License: https://www.myfonts.com/viewlicense?type=web&buildid=3697904
  33.                  * Licensed pageviews: 1,000,000
  34.                  * Webfonts copyright: Copyright &#x00A9; 2014 - 2016 Monotype Imaging Inc. All rights
  35.                  * reserved.
  36.                  *
  37.                  * © 2019 MyFonts Inc
  38.                 */
  39.                 -->
  40.         {{ include('Includes/appendStylesandScripts.html.twig') }}
  41.         {% if not document is defined or not document %}
  42.             {% set document = pimcore_document(navigationStartId) %}
  43.         {% endif %}
  44.         {% if document is instanceof('\\Pimcore\\Model\\Document\\Link') %}
  45.             {# @var document \Pimcore\Model\Document\Link #}
  46.             {% set document = document.getObject() %}
  47.         {% endif %}
  48.         {# TITLE #}
  49.         {% if seoTitle is defined and seoTitle is not empty %}
  50.             {{ pimcore_head_title(seoTitle) }}
  51.             {% do pimcore_head_meta().setName('og:title', seoTitle) | raw %}
  52.         {% elseif document.getTitle() is not empty %}
  53.             {{ pimcore_head_title(document.getTitle()) }}
  54.             {% do pimcore_head_meta().setName('og:title', document.getTitle()) |raw %}
  55.         {% else %}
  56.             {{ pimcore_head_title(document.properties.navigation_name.data) }}
  57.             {% do pimcore_head_meta().setName('og:title', document.properties.navigation_name.data) |raw %}
  58.         {% endif %}
  59.         {# DESCRIPTION #}
  60.         {% if seoDescription is defined and seoDescription is not empty %}
  61.             {% do pimcore_head_meta().setName('description', seoDescription)|raw %}
  62.             {% do pimcore_head_meta().setName('og:description', seoDescription ) |raw %}
  63.         {% elseif productMetaDescription is not empty %}
  64.             {% do pimcore_head_meta().setName('description', productMetaDescription)|raw %}
  65.             {% do pimcore_head_meta().setName('og:description', productMetaDescription ) |raw %}
  66.         {% elseif document.getDescription() is not empty %}
  67.             {% do pimcore_head_meta().setDescription(document.getDescription()) %}
  68.             {% do pimcore_head_meta().setName('og:description', document.getDescription()) |raw %}
  69.         {% endif %}
  70.         {% if product.getDetailViewRepresentationNew() %}
  71.             {% do pimcore_head_meta().setName('og:image', hostUrl ~document.getProperty('og-image') ) |raw %}
  72.         {% endif %}
  73.     {%- endspaceless %}
  74.     {% block layout_head_meta deferred %}
  75.     {# print meta #}
  76.     {{ pimcore_head_meta() }}
  77.     {% endblock %}
  78.     {% block head_stylesheets deferred %}
  79.     {{ pimcore_head_link() }}
  80.     {% endblock %}
  81.     {#{% block head_ie_stylesheets %}#}
  82.     {#<!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->#}
  83.     {#<!--[if lt IE 9]>#}
  84.     {#<script src="{{ asset('static/js/html5shiv.js') }}"></script>#}
  85.     {#<script src="{{ asset('static/js/respond.min.js') }}"></script>#}
  86.     {#<![endif]-->#}
  87.     {#{% endblock %}#}
  88.     {{ include('Includes/appendFavicons.html.twig') }}
  89. </head>