Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The tag 'script' is disallowed except in specific forms #261

Open
shakeel-latif opened this issue Apr 17, 2019 · 0 comments
Open

The tag 'script' is disallowed except in specific forms #261

shakeel-latif opened this issue Apr 17, 2019 · 0 comments

Comments

@shakeel-latif
Copy link

shakeel-latif commented Apr 17, 2019

Hi,

<script async src="https://cdn.ampproject.org/v0.js"></script>
    <script async custom-element="amp-bind" src="https://cdn.ampproject.org/v0/amp-bind-0.1.js"></script>
    <script async custom-element="amp-carousel" src="https://cdn.ampproject.org/v0/amp-carousel-0.1.js"></script>
    <script async custom-element="amp-form" src="https://cdn.ampproject.org/v0/amp-form-0.1.js"></script>
    <script async custom-template="amp-mustache" src="https://cdn.ampproject.org/v0/amp-mustache-0.2.js"></script>

i have added these libraries in my amp page.

only v0.js and amp-carousel libraries loading rest gives validation errors. i have added them in head tag.

<script async custom-element="amp-bind" src="https://cdn.ampproject.org/v0/amp-bind-0.1.js"> on line 31

  • The tag 'script' is disallowed except in specific forms.
    [code: GENERAL_DISALLOWED_TAG category: CUSTOM_JAVASCRIPT_DISALLOWED]
    ACTION TAKEN: script tag was removed due to validation issues.

<script async custom-element="amp-form" src="https://cdn.ampproject.org/v0/amp-form-0.1.js"> on line 33

  • The tag 'script' is disallowed except in specific forms.
    [code: GENERAL_DISALLOWED_TAG category: CUSTOM_JAVASCRIPT_DISALLOWED]
    ACTION TAKEN: script tag was removed due to validation issues.

<script async custom-template="amp-mustache" src="https://cdn.ampproject.org/v0/amp-mustache-0.2.js"> on line 34

  • The attribute 'src' in tag 'amp-mustache extension .js script' is set to the invalid value 'https://cdn.ampproject.org/v0/amp-mustache-0.2.js'.
    [code: INVALID_ATTR_VALUE category: CUSTOM_JAVASCRIPT_DISALLOWED see: https://www.ampproject.org/docs/reference/extended/amp-mustache.html]
    ACTION TAKEN: script.src attribute was removed due to validation issues.
  • FINAL ACTION TAKEN: script tag removed from head as it still does not validate. Could not fix tag validation problems.

Even when i try to comment amp-carousel it still add that script in the head.

please guide me what i'm doing wrong. thank

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant