#69 – AMP Error: Google Search Console

Posted in ‘weeblrAMP’
This is a public ticket. Everybody will be able to see its contents. Only enter usernames, passwords or any other sensitive information in the Private information field.
Wednesday, 11 April 2018 23:11 UTC
 Hello Again,

I recently submitted my site for Google Search Console AMP indexing, however for some reason, 20 (out of 500) of the pages spit back an error. And I cannot figure out why.

The Error: Invalid value for attribute in layout 'width' in tag 'amp-img'

The Code the Error is Referencing:

<amp-img src="https://media.truefacet.com/guide/wp-content/themes/child-wpex-fashionista/images/logo2.png" width="" height="" alt="" class="amp-logo" layout="responsive"></amp-img>

As I said, this is only happening to about 20 pages, not sure why it's not all or none.

Do you know how I can fix this?

Thursday, 12 April 2018 07:36 UTC

As the error says, the width attribute is invalid - because it is empty. I cannot comment much more as you did not provide links to real pages that show the error.

What I see on this code is the class "amp-logo". This is not something that was created by wbAMP (we do not use that CSS class), so I suspect you added that somewhere yourself to some content or template overrides? if so, you need to specify width and height of images in AMP tags.

Best regards

Friday, 27 April 2018 05:34 UTC
This ticket has been automatically closed. All tickets which have been inactive for a long time are automatically closed. If you believe that this ticket was closed in error, please contact us.
This ticket is closed, therefore read-only. You can no longer reply to it. If you need to provide more information, please open a new ticket and mention this ticket's number.