custom JavaScript not allowed

Posted in: Newspaper
Post count: 11

I am getting errors in the search console AMP section, telling “Custom javaScript not allowed

Post count: 27744

Hi,

This message appears in most cases when you set a custom JavaScript for ads and this is not allowed in the custom JavaScript section, please remove the code from there.
The codes for auto ads need to be set only in analytics -> https://i.imgur.com/bRcp2zK.png or in mobile theme > amp analytics -> https://i.imgur.com/gxVsaOe.png
That looks like an AMP error message
https://www.ampproject.org/docs/troubleshooting/validation_errors#custom-javascript-is-not-allowed

Thank you!

Post count: 11

I don’t know how to do it

Post count: 35449

Hi janaka99,
Did you add some code in theme panel or in some posts, pages, plugins? If no then, pleas make sure that there is no plugin that is interfering with the theme, disable all plugins except tagDiv plugins and amp and try again.
Let us know the results!

Post count: 11

I added the google Adsense script code. that’s the reason for custom javascript not allowed. how to fix that

Post count: 27744

Hello,

Can you take screenshots or a step-by-step video of how you did the implementations?

Thank you!

Viewing 6 posts - 1 through 6 (of 6 total)
The forum ‘Newspaper’ is closed to new topics and replies.