Viewing 8 replies - 1 through 8 (of 8 total)
  • Thread Starter lookahead.io

    (@lookaheadio)

    I am wondering if it has to do with the W3TC Cache generated minimized JScript file before </body> that is not loaded with async?
    e.g. <script type=”text/javascript” src=”https://c4.jeffreifman.com/wp-content/cache/minify/000000/68b0b/default.include-footer.952e41.js?d4992f”></script&gt;

    This still appears in the amp version.

    Also, the amp error seems to appear on all my site’s pages even though Google Search Console is only reporting it on 10.

    That is probably it. AMP won’t work with “injected” JavaScript since part of the concept is to strip out scripts. Also likely since no footer would need to be loaded from cache for the AMP version.

    So looks like disabling that would be first debug step.

    Thread Starter lookahead.io

    (@lookaheadio)

    not sure if w3tc makes that easy … amp is not super wordpress friendly.

    I may have to strip out my Jscript and include it manually – but then, that might kill my google page speed again – or I might be able to async it in the footer manually, not easy to maintain.

    Any other ideas welcome.

    Hello, can you share the URL with the AMP issue, so we can test further?

    THanks

    Hi Baloydi,

    All the pages on this site don’t work – it’s the W3TC cache include in the footer with customization – so you should be able to filter it. Please ping me when you have a patch in the plugin.
    https://jeffreifman.com/2016/03/24/are-abortions-now-1-for-men-in-washington-state/amp/#development=1

    My other site [Trademark infringement link moderated] works fine with the amp plugin.

    Based on checking the AMP validator points to this code:
    <amp-analytics type="googleanalytics" id="analytics1"><script type="application/json">{"vars":{"account":"UA-37244292-1"},"triggers":{"trackPageview":{"on":"visible","request":"pageview"}}}</script></amp-analytics><script type="text/javascript" src="https://c4.jeffreifman.com/wp-content/cache/minify/000000/68b0b/default.include-footer.85f827.js?752178"></script>

    What you can do is:
    Try to disable the WordPress plugins that may cause the adding of scripts, then check again on the AMP validator.

    You may also refer to this resource:
    https://asknoypi.com/accelerated-mobile-pages-validator/#script

    Let us know. Thanks

    There are some reason for these errors:
    1. Plugin contain script –> Just deactive all of plugin step by step to find the plugin issue
    2. Theme wordpress contain script –> just deactive theme wordpress step by step to find the theme wordpress issue
    3. You inserted some javascript on your wordpress –> just check and remove theme
    4. Check Kaspersky Anti-virus on your laptop. Do you install any virus SW like Kaspersky? Because it will auto insert the tag script on your website.
    –> Just check it by view page source. if you see the tag script, then just uninstall the Kaspersky. then can fix the issue.

    If you want more detail, can refer to my website ([](https://quanglepro.com/cach-sua-loi-tag-script-is-disallowed-google-amp)

    –> But i write in Vietnamese, so you can change it into English by google stranslation. Hope it can help you.

    mine was fixed with taking out the Yoast SEO AMP Glue analytic code.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘The tag 'script' is disallowed except in specific forms.’ is closed to new replies.