Title: Invalid inline script &amp; Invalid attribute: emoji-amp problem
Last modified: September 2, 2020

---

# Invalid inline script & Invalid attribute: emoji-amp problem

 *  Resolved [johnbrad](https://wordpress.org/support/users/johnbrad/)
 * (@johnbrad)
 * [5 years, 9 months ago](https://wordpress.org/support/topic/invalid-inline-script-invalid-attribute-emoji-amp-problem/)
 * when i add photos in the article say problem with amp
 * Invalid inline script
 * Information
    AMP does not allow the use of JS <script> tags unless they are for
   loading AMP components, which are added automatically by the AMP plugin. For 
   any page to be served as AMP, all invalid script tags must be removed from the
   page. Instead of custom or third-party JS, please consider using AMP components
   and functionality such as amp-bind and actions and events (as opposed to JS event
   handler attributes like onclick). Some custom JS can be added if encapsulated
   in the amp-script. Learn more about how AMP works.
 * If all invalid markup is “removed” the page will be served as AMP. However, the
   impact that the removal has on the page must be assessed to determine if the 
   result is acceptable. If any invalid markup is “kept” then the page will not 
   be served as AMP.
 * Error code
    DISALLOWED_TAG Invalid markup <script … > Element attributes type
   text/javascript Element name script Parent element head
 * —————–
 * Invalid attribute: emoji-amp
 * Information
    AMP allows a specific set of elements and attributes on valid AMP
   pages. Learn about the AMP HTML specification. If an element or attribute is 
   not allowed in AMP, it must be removed for the page to be cached and eligible
   for prerendering.
 * If all invalid markup is “removed” the page will be served as AMP. However, the
   impact that the removal has on the page must be assessed to determine if the 
   result is acceptable. If any invalid markup is “kept” then the page will not 
   be served as AMP.
 * Error code
    DISALLOWED_ATTR Invalid markup <html … emoji-amp=”” …> Element attributes
   emoji-amp lang en-US amp data-ampdevmode Attribute name emoji-amp Parent element
   html

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Contributor [Marko Vasiljevic](https://wordpress.org/support/users/vmarko/)
 * (@vmarko)
 * [5 years, 9 months ago](https://wordpress.org/support/topic/invalid-inline-script-invalid-attribute-emoji-amp-problem/#post-13354527)
 * Hello [@johnbrad](https://wordpress.org/support/users/johnbrad/)
 * I am sorry about the issue you are experiencing and I am happy to assist you 
   with this.
    Can you please confirm that the issue persists if you disable W3 
   Total Cache so we can determine if the issue is related to W3TC? In Performance
   >Extensions there is an AMP extension that you should enable if you are using
   the AMP plugin. Can you please confirm if that extension is enabled? Thanks!
 *  Plugin Contributor [Marko Vasiljevic](https://wordpress.org/support/users/vmarko/)
 * (@vmarko)
 * [5 years, 9 months ago](https://wordpress.org/support/topic/invalid-inline-script-invalid-attribute-emoji-amp-problem/#post-13386343)
 * No activity for a week.
    Marking topic as resolved.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Invalid inline script & Invalid attribute: emoji-amp problem’ is closed
to new replies.

 * ![](https://ps.w.org/w3-total-cache/assets/icon-256x256.png?rev=1041806)
 * [W3 Total Cache](https://wordpress.org/plugins/w3-total-cache/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/w3-total-cache/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/w3-total-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/w3-total-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/w3-total-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/w3-total-cache/reviews/)

## Tags

 * [css](https://wordpress.org/support/topic-tag/css/)
 * [java-script](https://wordpress.org/support/topic-tag/java-script/)

 * 2 replies
 * 2 participants
 * Last reply from: [Marko Vasiljevic](https://wordpress.org/support/users/vmarko/)
 * Last activity: [5 years, 9 months ago](https://wordpress.org/support/topic/invalid-inline-script-invalid-attribute-emoji-amp-problem/#post-13386343)
 * Status: resolved