Title: Disallowed attribute value
Last modified: December 21, 2021

---

# Disallowed attribute value

 *  Resolved [xylo04](https://wordpress.org/support/users/xylo04/)
 * (@xylo04)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/disallowed-attribute-value/)
 * I’m using the Google Search Console to flag SEO problems, and it started alerting
   with an error:
 *     ```
       Disallowed attribute or attribute value present in HTML tag.
   
       The attribute 'loading' in tag 'img' is set to the invalid value 'eager'.
       ```
   
 * I can verify that the offending attribute `loading="eager"` is in the AMP HTML,
   and I don’t see any documentation about that being an official attribute. Is 
   this a custom attribute? If yes, should it be prepended with `data-` per [https://developer.mozilla.org/en-US/docs/Learn/HTML/Howto/Use_data_attributes](https://developer.mozilla.org/en-US/docs/Learn/HTML/Howto/Use_data_attributes)?
 * If it helps, I have a support UUID: ampwp-9f8179b3-f145-555a-a154-8d6bfe387cf1.
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fdisallowed-attribute-value%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

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

 *  [Fellyph Cintra](https://wordpress.org/support/users/fellyph/)
 * (@fellyph)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/disallowed-attribute-value/#post-15187605)
 * Hi [@xylo04](https://wordpress.org/support/users/xylo04/),
 * Thanks for getting in contact with us, my name is Fellyph and I will help you
   today. I have looked at your website, the loading property is valid for HTML,
   but AMP uses a different tag for images: [https://amp.dev/documentation/components/amp-img](https://amp.dev/documentation/components/amp-img)
 * There is a plugin for flicker gallery, injecting invalid AMP content, if you 
   want to keep using this plugin you can disable AMP for this particular page or
   use the Gutenberg gallery block, that is compatible with AMP.
 *  Plugin Author [Weston Ruter](https://wordpress.org/support/users/westonruter/)
 * (@westonruter)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/disallowed-attribute-value/#post-15189162)
 * > I can verify that the offending attribute loading=”eager” is in the AMP HTML
 * Could you clarify this? You’re seeing `loading=eager` in the AMP spec? Only `
   loading=lazy` is currently allowed for normal AMP documents ([ref](https://github.com/ampproject/amphtml/blob/18c57b263a7254b5a75e0cf1d7bcb187e5000ef8/validator/validator-main.protoascii#L1803-L1806)).
 * There is also `loading=eager` which is allowed on Optimized AMP pages which are
   transformed from normal AMP pages to add server-side rendering ([ref](https://github.com/ampproject/amphtml/blob/18c57b263a7254b5a75e0cf1d7bcb187e5000ef8/validator/validator-main.protoascii#L4130-L4134)).
 * In general, when wanting to ensure an image is loaded eagerly it is best to omit
   the `loading` attribute altogether, as in Chromium-based browsers that allows
   them to follow the `auto` behavior that respects the user being in “data saver”
   mode, to lazy-load images by default when on slow connections.
 *  Thread Starter [xylo04](https://wordpress.org/support/users/xylo04/)
 * (@xylo04)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/disallowed-attribute-value/#post-15189610)
 * Fellyph, Weston, thanks for the responses. I suspect Fellyph is correct here,
   the Flickr Gallery plugin isn’t rendering correct AMP-safe HTML. We’re not doing
   anything explicit to use the `loading` attribute, and I don’t see any configuration
   in the Flickr plugin that would adjust what it’s outputting. We’ll probably just
   disable AMP for that page.
    -  This reply was modified 4 years, 5 months ago by [xylo04](https://wordpress.org/support/users/xylo04/).
 *  [Fellyph Cintra](https://wordpress.org/support/users/fellyph/)
 * (@fellyph)
 * [4 years, 5 months ago](https://wordpress.org/support/topic/disallowed-attribute-value/#post-15190332)
 * Hi [@xylo04](https://wordpress.org/support/users/xylo04/),
 * You can disable AMP only for one page at the post settings:
 * About the Flickr plugin, we will investigate if we can find a solution to turn
   around this issue.
 *  [Fellyph Cintra](https://wordpress.org/support/users/fellyph/)
 * (@fellyph)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disallowed-attribute-value/#post-15222147)
 * As we didn’t receive a response I’ll mark this as resolved. Feel free to open
   a [new support topic](https://wordpress.org/support/plugin/amp/#new-post) if 
   you require any further assistance.
 *  [Fellyph Cintra](https://wordpress.org/support/users/fellyph/)
 * (@fellyph)
 * [4 years, 4 months ago](https://wordpress.org/support/topic/disallowed-attribute-value/#post-15265143)
 * .

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

The topic ‘Disallowed attribute value’ is closed to new replies.

 * ![](https://ps.w.org/amp/assets/icon.svg?rev=2527602)
 * [AMP](https://wordpress.org/plugins/amp/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/amp/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/amp/)
 * [Active Topics](https://wordpress.org/support/plugin/amp/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/amp/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/amp/reviews/)

## Tags

 * [amp-img](https://wordpress.org/support/topic-tag/amp-img/)
 * [img](https://wordpress.org/support/topic-tag/img/)

 * 6 replies
 * 3 participants
 * Last reply from: [Fellyph Cintra](https://wordpress.org/support/users/fellyph/)
 * Last activity: [4 years, 4 months ago](https://wordpress.org/support/topic/disallowed-attribute-value/#post-15265143)
 * Status: resolved