• Resolved saranrock

    (@saranrock)


    Hi, Please help me with this, Recently I Create my First Web Story, But I am facing an issue with AMP.

    I got an error from the Google Search console that shows that ” Custom JavaScript is not allowed. ”

    When I check with stories on AMP testing tool I found that Web Stories is Invalid

    Please tell me how to fix this issue. Also I have submitted the Site helth information through this , please check and let me know if you found any issues. Thanks in Advance

    • This topic was modified 2 years, 7 months ago by saranrock.

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

Viewing 11 replies - 1 through 11 (of 11 total)
  • Thread Starter saranrock

    (@saranrock)

    Hi, I found that conflict plugin. WP for the AMP plugin is causing the issue. Either you or AMP for WP author needs to fix these compatibility issues.

    Once I deactivate that wp for the AMP plugin the web stories become valid. https://prnt.sc/tfZvcauxM2WT

    Thanks in Advance. Please help me ASAP. I also informed about this to AMP for WP author. I am waiting for their reply

    • This reply was modified 2 years, 7 months ago by saranrock.
    Plugin Support Luckyna San

    (@luckynasan)

    @saranrock Thank you for your report. It seems the plugin is inserting custom JavaScript, which is not allowed in Web Stories. Could you check if you have Gravity Forms set up in AMP for WP plugin Settings > Contact Forms > Gravity Forms Support?

    Thread Starter saranrock

    (@saranrock)

    HI Luckyna San,

    I checked my site, I have not installed gravity forms on my site. Here is the screenshot

    https://prnt.sc/n8BkasQPbV3_

    Plugin Support Luckyna San

    (@luckynasan)

    @saranrock The validation error may actually be coming from WP Rocket because it looks like RocketLazyLoadScripts is in the offending JS. Can you disable the option to Delay Javascript Execution by navigating to WP Rocket > File Optimization tab > Delay Javascript Execution? Then retest your story for any AMP validation errors.

    Thread Starter saranrock

    (@saranrock)

    Hi, thanks for your support. I haven’t done anything But the problem is fixed.
    Now the stories are Valid.

    I will let you know if the problem comes again. Thanks

    Thread Starter saranrock

    (@saranrock)

    Sorry for the Above message. I think you’re right. WP Rocket is generating the Custom Javascript code. Once I deactivate the WP rocket plugin the error is gone but when I activate the WProcket plugin the errors appear again.

    I tried your mentioned step by unchecking and checking the box but it doesn’t work.

    Please check the image for reference

    https://prnt.sc/1xGUyfhTP_1H

    Plugin Support Luckyna San

    (@luckynasan)

    @saranrock Thanks for the update.

    Could you check if the plugin’s minification options for JavaScript/CSS files have been enabled? This can be found by navigating to Settings > WP Rocket > File Optimization > Minify CSS files and Minify JavaScript files.

    You can try disabling these options, clearing cache, and retesting the story URL once more on the AMP test tool.

    Thread Starter saranrock

    (@saranrock)

    Hi, It worked after Unchecking both Minify Javascript files and Delay javascript Execution.

    I am happy that now my web stories become Valid and I can see Web stories are a valid message on the AMP testing tool.

    But the only concern is My website loading time. It increases a bit. Because when I uncheck these two things it won’t reduce Javascript files and Minify Javascript files. So this is the reason for an extra bit of loading time.

    Is there anything you can do or this is the only option.

    Thanks for your support

    Plugin Support Luckyna San

    (@luckynasan)

    @saranrock Thank you for the update. You can report this issue to them as well if disabling these optimizations is not an option for you.

    You could try to exclude the “/web-stories/(.*)” URL in the settings to prevent optimization on those posts under Advanced Rules > Never Cache URL(s).

    Please let me know how you get on with this.

    Thread Starter saranrock

    (@saranrock)

    Hi, Thank you so much. I excluded web stories from the cache now is working fine.

    Plugin Support Luckyna San

    (@luckynasan)

    @saranrock Glad to help. Please open a new support if you have other issues or questions.

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘Web Story is invalid’ is closed to new replies.