- This topic has 9 replies, 2 voices, and was last updated 3 years, 9 months ago by
David.
-
AuthorPosts
-
July 10, 2022 at 4:54 am #2278402
Kevin
Hi, For some reason my site is generating vast amounts of images every time I upload a file to my media library. Shortpixel has confirmed this but can find no error on their end. It’s either my theme or plugins.
Since adding Ezoic, my site is slowing, and optimizing thousands of images is crazy.
Plus I dont want to pay Shortpixel to optimize all this stuff.
Thanks in advance.
July 10, 2022 at 6:05 am #2278430David
StaffCustomer SupportHi there,
WP should only create additional images for any registered image sizes ( by default that is thumbnail, medium, medium_large and large ). Other plugins may also add sizes, for example Woocommerce adds their own specific sizes too.
But GP doesn’t add any additional sizes. And way back in GP Premium 1.1 we removed our on the fly image resizer, which was only used by the Featured Image options in the Blog settings. Which pretty much rules out the Theme being an issue.
Did the issue occur since adding Ezoic? As i know they do some stuff with images too ?
If not – can you share an example where i can see the many versions of the image thats being created ?
July 10, 2022 at 8:33 am #2278656Kevin
Thanks for the reply. I will see if Ezoic has anything to do with it.
I don’t really know where to find all the versions. All I know is shortpixel eats the credits.
July 11, 2022 at 2:24 am #2279100Kevin
Hi David, Ezoic doesn’t think it’s them.
I found the destination of my images and hopefully this linkwill take you to the screenshot. This one is the most extreme.
I made an error with this image and loaded it more than once. Even so, you can see 3 file types and various sizes.
Can you tell me what I’m doing wrong?
I appreciate it may not be GP doing this but any help would be appreciated.
Cheers
July 11, 2022 at 2:27 am #2279104Kevin
July 11, 2022 at 3:12 am #2279149David
StaffCustomer SupportSo apart from the 100px size which i assume has been registered by plugin, the sizes:
150px
thumbnail, 300medium, 768pxmedium_large, 1024pxlargeare the default WP sizes.
If you wanted to remove any of those registered sizes so WP doesn’t generate them any more for new image uploads then the first snippet in this doc will do that:
https://developer.wordpress.org/reference/functions/remove_image_size/#comment-1379
For example, this would remove the
thumbnailandmediumsizes.function wpdocs_remove_plugin_image_sizes() { remove_image_size( 'thumbnail' ); remove_image_size( 'medium' ); } add_action('init', 'wpdocs_remove_plugin_image_sizes');Of course you need to make sure you don’t remove ones your site is specifically using. The Theme itself doesn’t dictate the sizes you need but some plugins may expressly request a certain size. As a general note, considering most device screens have a DPR of x2,x3 or greater then even if you’re displaying a 300px wide image, the browser will grab a 2 – 3x larger size, and so medium_large and large images are more likely to be required over the smaller images.
OK then i see:
can-you-draw-on-canvasandcan-you-draw-on-canvas-1– i assume only one image was uploaded ?July 11, 2022 at 5:00 am #2279285Kevin
Hi David, In the example I sent, it was probably a double listing. That said, my recent uploads mostly loaded with the wrong file type.
I loaded Jpg files, but they ENTERED as PNG files. I saw each file switch in front of me. That’s one of the reasons I tried to re-enter some of the files. I cleared the cache, logged out, and back in again, and still it happened.
I allowed the WebP setting because I read that it was a good idea. I don’t know if that was wise or not.
What do you think? Why would the files switch to PNGs as I load them?
Cheers
July 11, 2022 at 5:19 am #2279302David
StaffCustomer SupportThe PNG thing – sorry i thought we had covered that here:
https://generatepress.com/forums/topic/my-jpg-image-auto-converts-into-png-file/#post-2217462
Did you check with Ezoic about disabling their image optimizations ?
July 11, 2022 at 1:10 pm #2279834Kevin
Oh yes, you are right. I’d forgotten. I will get back to them.
Cheers
July 12, 2022 at 2:40 am #2280261David
StaffCustomer SupportYou’re welcome!
-
AuthorPosts
- You must be logged in to reply to this topic.