Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1066653

    I have been looking at ways to improve my site performance.

    GTmetrix highlights some images on my home page that “are missing width and/or height attributes.”

    The page is created in ALB and the images concerned are loaded via the Image element, which does not offer the ability to specify image dimension attributes.

    How can I do this and solve the GTmetrix error message?

    #1067163

    Hey zimbo,

    Could you please attach some screenshots of the issue?

    Best regards,
    Victoria

    #1067468

    Screenshot from GTmetrix report.

    Screenshot of the page in ALB where the images are specified.

    Home page generating the GTmetrix report.

    If you look at the page source in Dev Tools you will see the img code for the sponsor logos do not have any dimensions…

    <img src="https://www.henleyherald.com/wp-content/uploads/2016/08/brakspear-2017-logo.jpg" alt="" />

    …whereas the first Top Story image does:

    <img width="260" height="185" src="https://www.henleyherald.com/wp-content/uploads/2019/02/invesco-helen-douglas-cheque-260x185.jpg" alt="" />

    #1068743

    Hi,

    Thank you for using Enfold.

    We can’t specify the width and height of those images because they have to inherit the size of their parent container, making them much more responsive on different screen sizes. Anyway, the score is almost perfect even with those warnings, so you can just ignore that.

    Best regards,
    Ismael

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.