• Resolved egornmore

    (@egornmore)


    Hello, I am trying to figure out how I can change Meta Viewport. I am using Neve Theme and in ‘header.php’ (Screenshot 1) the meta viewport tag differs from what is shown in inspect (Screenshot 2). Does the AMP plugin overwrites theme declaration?

    Screenshot (1): https://ibb.co/LZtzByB
    Screenshot (2): https://ibb.co/x3jjXL2

    • This topic was modified 2 years, 10 months ago by egornmore.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Weston Ruter

    (@westonruter)

    Yes it does, to improve performance. Please see: https://github.com/ampproject/amp-wp/issues/5894

    Does this cause a problem for you?

    Thread Starter egornmore

    (@egornmore)

    I am having troubles with img sizes media queries, here is my code:

    <img
    alt="'. $hero_image_alt .'"
    src="'. $hero_img_url_530w[0] .'"
    srcset="'. $hero_img_url_360w[0] .' 360w,
            '. $hero_img_url_1470w[0] .' 1470w"
    sizes="(min-device-width: 360px) and (max-device-width: 480px) 360px,
           (min-device-width: 481px) 1470px,
           1470px"
    disable-inline-width data-hero />

    Media queries work fine with DPR:2 or less but don’t work with DPR:3 devices for some reason, not sure if adding “initial-scale=1” viewport meta will help, just investigating… Maybe there is a PHP filter to add initial-scale=1?

    • This reply was modified 2 years, 10 months ago by egornmore.
    • This reply was modified 2 years, 10 months ago by egornmore.
    • This reply was modified 2 years, 10 months ago by egornmore.
    • This reply was modified 2 years, 10 months ago by egornmore.
    Thread Starter egornmore

    (@egornmore)

    Disabled AMP to test it with ‘initial-scale=1’, meta is not an issue. Thank you for the fast reply! =)

    • This reply was modified 2 years, 10 months ago by egornmore.
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Meta Viewport Question’ is closed to new replies.