Magento2: Adding http-equiv meta tag in default_head_blocks.xml

Created on 28 Jun 2017  路  5Comments  路  Source: magento/magento2


Preconditions


  1. Magento 2.1.7
  2. Apache 2.4 / PHP 7.0.19

Steps to reproduce

  1. In your Theme add a "Magento_Theme/layout/default_header_blocks.xml" file
  2. add a head section with
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />

Expected result

  1. When rendering the HTML der should be a
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
    somewhere in the Head section

Actual result

  1. After Rendering the HTML the following can be found:
    <meta name="" content="IE=edge,chrome=1" />


Also tried other types of meta tags (property, itemprob) they also get removed.

Frontend Confirmed Format is valid Ready for Work Reproduced on 2.1.x Reproduced on 2.2.x Reproduced on 2.3.x bug report

Most helpful comment

You should use <meta name="x_ua_compatible" content="IE=edge,chrome=1"/>
See getMetadataTemplate in magento/framework/View/Page/Config/Renderer.php for details

All 5 comments

@RedEnzian, Thanks for reporting this issue.
We've created internal ticket MAGETWO-70448 to address this issue.

You should use <meta name="x_ua_compatible" content="IE=edge,chrome=1"/>
See getMetadataTemplate in magento/framework/View/Page/Config/Renderer.php for details

@RedEnzian, thank you for your report.
We've created internal ticket(s) MAGETWO-70448 to track progress on the issue.

I am working on this one, can you please assign it to me? #squashtoberfest

I think this one could be resolved with documentation rather than code as @pooshok has mentioned.

@okorshenko @magento-engcom-team

Was this page helpful?
0 / 5 - 0 ratings