Images in sliders


#1

Hello,

I just made my site live (http://theartofauthenticliving.com) and my scores are terrible on PageSpeed Insights and GTmetrix due to the images in my sliders (which are supposedly being resized using HTML or CSS). My site loads fast enough in my opinion, but I’m concerned about having such low scores for SEO purposes (22 mobile, 9 desktop for Google).

Is there any code that you can provide that can address this issue? Alternatively, can you recommend a plugin or make any other recommendations? For the record, my other site (kristismithyoga.com) uses Sydney Pro and has great scores…I’m not using a slider currently, but when I was I didn’t have any issues with the images.

Btw, I use Imsanity and EWWW Optimizer (cloud version) and WPEngine for a host.

Thanks!


#2

Hi,

I see what you mean. The issue is with the slider in the gallery format.
It will be fixed. Meanwhile, do this please:

  • go to Appearance > Editor;
  • find content-gallery.php in the list of files;
  • replace the contents with this.

#3

Thanks, Vlad.

When I paste that code, the gallery disappears on my home page…

I’m going to revert back to the original code so that the gallery is visible until a solution is reached. Thanks!


#4

That’s strange, it works fine for me. I even added it to the demo site and it was working fine. Have you cleared your cache after you tried?
Anyway, that’s the only way to automatically get smaller versions of your images. If that isn’t working for you for some reason, you’ll need to manually add smaller images to your library and select those for your gallery


#5

It still didn’t work even after I cleared the cache. Is it possible that a small piece of code wasn’t copied over from where ever you wrote it? I don’t understand why it’s not working.

I can manually upload smaller images to the gallery, but when people click on the link, I want them to be able to view the normal/full sized images. If it’s impossible for some reason for the code to work (eg, my installation of the theme or Wordpress is possessed), is there a way to do this? Thanks.


#6

I should add that it’s displaying the broken link icon - I’ll leave the code that I got from your link up for a bit so that you can see what I mean.


#7

Thing is that your images won’t be displayed larger than 750px on single posts either, so there’s not much point in using 2000px wide images.

With the new code on, try to delete them and re-add them. I mean delete them completely from your media library and then re-select them for your gallery. Or even upload and select new images if that’s easier.


#8

This is Kristi (I’m signed in using my husband’s account). Deleting and re-adding the images solved the problem. Thanks, Vlad!


#9

Ugh, so the issue has returned, apparently(?).

  1. I updated the theme yesterday or today
  2. Google PageSpeed Insights shows a mobile score of 87 :slight_smile: but a desktop score of 11 :frowning: due to images
  3. I tried repasting the code from the link at the beginning of this thread to see if that would work, but it didn’t do anything
  4. I deleted the slider images from the gallery and library and uploaded new ones. It works again (I had to re-analyze it a few times before my PageSpeed Insights desktop score would improve…it’s 91 now, which I think is lower than what it was before for some reason…but I know that it’s still decent).

Anyway, not to sound like a royal pain, but whenever the next update comes out can it include this code (or whatever) so that I don’t have to go through this again with the gallery php file? I suck at this sort of thing! Lol. Thanks, Vlad!


#10

Yeah, I didn’t do any changes in the last update, just changed from the update server to our own. And it had to happen fast.

You should activate the license on your husband’s site too so he can receive updates, I see you only have it active on a single site at the moment.