Support » Plugin: AMP » AMP issues detected by Google search console

  • Resolved andrbarbieri

    (@andrbarbieri)


    I activated the AMP using your guide.
    In the theme panel–> mobile settings, I activated the Mobile + AMP use-
    Now, all my websites, all with newspaper theme, have an issue with the search console of google.

    The issues in the google search console are:
    1) The tag ‘noscript enclosure for boilerplate’ appears more than once in the document.
    2) Only amp-boilerplate and amp-custom ‘style’ tags are allowed, and only in the document head.

    What is wrong? The performance are actually improved, but in 24h I received this issue.
    Can you help me? Thank you really much!

    The page I need help with: [log in to see the link]

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Weston Ruter

    (@westonruter)

    @andrbarbieri Thanks very much for sharing the example URLs.

    The markup that is causing the problem is:

    <noscript><style type="text/css"> .wpb_animate_when_almost_visible { opacity: 1; }</style></noscript>

    So first of all, there appears to be a bug with the AMP plugin because this should have been unwrapped and handled automatically.

    Can you identify which theme/plugin is introducing that code? If so, I can help make a workaround to fix the problem for you right away, but then I will also fix the AMP plugin to deal with this properly.

    Plugin Author Weston Ruter

    (@westonruter)

    I tried creating a plugin to reproduce the issue: https://gist.github.com/westonruter/2f6ea3b037336c10e3e344f55fcee4ce

    But the AMP plugin was able to deal with it as expected (unwrapping the noscript and combining the style with the rest of style[amp-custom]). So apparently the code is getting injected into the page at a layer above normal WordPress way.

    andrbarbieri

    (@andrbarbieri)

    First of all thanks you Weston for your quick reply.

    I use Newspaper theme version 9.7.2. They reccommend your plugin and the performance are noe great, so I want it to work properly!
    The theme has installed some plugins from TagDiv such as: 1. “tagDiv Composer”, 2.”tagDiv Mobile Theme”, 3. “tagDiv Speed Booster”, 4. “WPBakery Page Builder”. The last one I think is the one that create that strange sytle, so I deactivated it.

    Consider that Google says it will take several days to check. So if you think this could be the problem I can ask google to validate.

    Here you can find exact Google error:
    for the page
    /cucce-cani-interno/?amp

    1) “The tag ‘noscript enclosure for boilerplate’ appears more than once in the document”

    and the error highlighted by the google search console is:
    ><noscript><style amp-boilerplate>body{-webkit-animation:none;-moz-animation:none;-ms-animation:none;animation:none}</style></noscript></head><body class=”post-template-default single single-post postid-402 single-format-standard wpb-js-composer js-comp-ver-5.7 vc_responsive” itemscope=”itemscope” itemtype=”https://schema.org/WebPage”>

    2) “Only amp-boilerplate and amp-custom ‘style’ tags are allowed, and only in the document head.”
    and the error in the search console is

    ><style type=”text/css”> .wpb_animate_when_almost_visible { opacity: 1; }</style></noscript><style amp-boilerplate>body{-webkit-animation:-amp-start 8s steps(1,end) 0s 1 normal both;-moz-animation:-amp-start 8s steps(1,end) 0s 1 normal both;-ms-animation:-amp-start 8s steps(1,end) 0s 1 normal both;animation:-amp-start 8s steps(1,end) 0s 1 normal both}@-webkit-keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}@-moz-keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}@-ms-keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}@-o-keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}@keyframes -amp-start{from{visibility:hidden}to{visibility:visible}}</style><noscript><style amp-boilerplate>body{-webkit-animation:none;-moz-animation:none;-ms-animation:none;animation:none}</style></noscript></head><body class=”post-template-default single single-post postid-402 single-format-standard wpb-js-composer js-comp-ver-5.7 vc_responsive” itemscope=”itemscope” itemtype=”https://schema.org/WebPage”>

    Please give me any advice. I have 5 website with this error!

    Thanks for help! Andrea

    Plugin Author Weston Ruter

    (@westonruter)

    Since you are using tagDiv themes and plugins, and since tagDiv modifies how the AMP plugin works, I think your best bet for getting help here is to reach out to tagDiv support directly: http://forum.tagdiv.com/

    I’ve also reached out to them directly about this issue.

    Plugin Author albertomedina

    (@albertomedina)

    In the mean time, if deactivating the WP Bakery plugin removes the error, you can ask Google (via Search Console) to validate the fix.

    Hi guys actually it worked, I have a question.

    Is it normal that from mobile if I click on one of my pages the URL result is this?

    https://www.google.com/amp/s/www.giochi-da-tavolo.it/puzzle-3000/%3famp

    Is that %3famp normal.

    It is on EVERY of my webpages displayed through google from mobile.

    Also, Analytcs do not display this result, but display only the:
    https://www.google.com/amp/s/www.giochi-da-tavolo.it/puzzle-3000/?amp=

    Thank guys I appreciate really much your help.

    • This reply was modified 3 months, 3 weeks ago by  andrbarbieri.
Viewing 6 replies - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.