AMP error

Posted in: Newspaper
Post count: 497

Dear, I have experiencing issue with the Google Search Console Error “Custom Javascript Not Allowed”. After googling the error, I have found the solution that I have to Opt out from the Help US Support tab, But I couldn’t find that Opt Out tab in SRS Portal. Kindly suggest me how can I Opt out from the Support and Solve my Solution.

After googling I have find out the solution that I have to OPT out from Helping Us in case of Go Daddy to resolve the AMP Error Custom Javascript Not Allowed, but my Hosting Interface didn’t provide me such option. Please suggest me the solution that how can I fix that error by opting out from the support forum…

For More referrence, please do watch this video to understand the solution of the error.

Almost all my posts are affected with this problem.

https://www.pakdefense.com/blog/

Please take a look at this solution for further referrence…

Post count: 20688

Hi,

From what I can see AMP is not currently enabled on your website, so I can’t see where the error leads to. In most cases the javascript code it detects is either inserted by a plugin or is inserted manually somewhere in the theme panel. There could be other causes as well, but usually those are the ones.

If you should re-enable AMP I will take a look.

Thanks

Post count: 497

Dear, I have disabled the amp for first three posts, while remaining is enabled. Plz check after the first three posts. Examine and suggest me the solution…

Regards,

Post count: 20688

From what I can see the error is generated because of a script entered in the sub-footer section in the theme panel – http://prntscr.com/nxbdps
So this is what is causing the AMP error – http://prntscr.com/nxbdvy try removing it and test again with the validator – https://validator.ampproject.org/

Post count: 497

Dear, there are over 28 pages that are affected by the amp error. Do I have to remove the footer script to remove all the errors?

Is there any single issue and would be resolve after removing the script???

Post count: 20688

The footer is displayed in all the website, so the error would appear for all the AMP posts. Removing it should eliminate the issue for all of the posts at once.

To test this, remove the script entered in the sub-footer, clear the cache, and test a post with the AMP validator. It should pass the validation.

Post count: 497

Thanks Simion. I will give it a try. It was very helpful as always. If I want to use the script in the footer, then is there any method to pass the validation test while using the script?

Thanks again…

Post count: 20688

From what I know custom javascript is not allowed in AMP, there will be an error. To display it only on non-AMP pages, you could enter the script in a text widget in first the footer column – http://prntscr.com/ny89mv
That won’t be loaded on AMP but it will appear in desktop. You could give it a try.

Viewing 8 posts - 1 through 8 (of 8 total)
You must be logged in to reply to this topic.