Serving scaled images

Posted in: Newspaper
Post count: 2

Hi,

We ran our site through GTMetrix and the biggest issue it pointed was serving scaled images. What confuses us is that it says that it resizes images from 326×235 to 190×137 even though there are no images of the latter size. Can you let us know what’s happening and how to fix it?

Thanks

Post count: 9544

You should check to see if you have any ad modules running which resize images to fit, or if you’re using a sidebar element not part of theme (like a plugin, etc.), which is resizing images like a “related posts” plugin or similar.

If images are being resized from the generated thumbnail via CSS, it often means the next smaller size is missing (be sure to regenerate thumbnails for your old posts, if you have not already).

Obviously it would help to include the link to the GTMetrix report, or to your page where the error is happening for folks to look at.

Also note with GTMetrix it will often show you the names of the files being resized, so you can look at your source code and the page online to debug where that is happening based on file name, and then see if something is off from there.

  • This reply was modified 12 years by simchris.
Post count: 171

I also have the same problem, the widget that is sending the scaled images is the tagdiv slider.

Post count: 98

Jetpack’s Photon is resizing images on the fly. Are you using Photon? Becasue I’m using and I have same thing and this is not a problem for me. My page speed is enough for me. GTMetrix and Google Insights says same things: Optimize images.

Post count: 6600

Hi,

I know that we have cropped images for each block/modules/slider and the theme doesn’t serve any scaled images via CSS. I’ve tested our demo where is a slider there and tell me something about a scaled image but if i inspect the image with inspector the image is perfect fit no scale there.

Post count: 555

I’m having the same issue as well,and don’t have a clue how to make it go away..???????

Post count: 4

I was just checking this out also and the same thing applies for featured images in module 9 category. Image size is 326Ă—235 but in reality the picture is showed in 260×187, but there ain’t thumbnails for that size.

CSS code that does this is:
.td_mod9 .thumb-wrap img {
max-height: 187px;
max-width: 260px;
position: absolute;
}

Post count: 854

hi,
on the slider there is no resize of the images : http://screencast.com/t/13cy3l22f

on module 9 the image is scaled because it will look like this : http://screencast.com/t/aF6IwoQfDbnZ

we do it this way so we don’t need to cut another image.

if you want to have the image with the size : 260 x 187 px add it here : http://screencast.com/t/SLPKrlsX
then change in the module 9 : http://screencast.com/t/SLPKrlsX
then use the Regenerate thumbnails plugin to create that image size.

hope this help.

Thanks for you message.
Radu A.

Post count: 4

Thanks for the information.

Post count: 17

I am having the same issue from last few days. My page size went up from 1mb to 2.5 mb. This started happening when i got mod_pagespeed enabled on server. Please check http://gtmetrix.com/reports/www.moviereviewpreview.com/hgGcN1aA

Post count: 9544

@mrpb
make sure you experiment with the best mod_pagespeed settings, perhaps using some of my own settings for apache based servers from the page speed sticky at top of forum.

The theme has no settings for mod_pagspeed — that is managed by you via your htaccess file and the server config file.

Post count: 17

Hi Christopher,

I tried almost everything. But the issue is either theme or mod_pagespeed is scaling images from css and not using thumbnails.

What should i do?

Maddy

Post count: 9544

* Did you setup mod_pagespeed to work with your CDN ?

You have to setup sharding or origin domain settings for mod_pagespeed to work with a CDN.
https://developers.google.com/speed/pagespeed/module/domains#mapping_origin

* Also, check to see if the thumbnails are actually being written in your images directory.

Did you regenerate all your thumbnails for the theme when switching to it, so that the thumbnails are actually there?

Either of those would be my first suggestion.

Post count: 17

You are right. Thumbnails are not being created. I had to recreate them through a plugin. I am using this theme since last few months, this happened right after i started using mod_pagepseed.

What can i do to fix thumbnails issue?

Post count: 9544

Review the docs on mod_pagespeed and your CDN.

The theme creates the thumbnails when *not* using CDN wiht mod_pagespeed; the theme creates thumbnails when using mod_pagespeed, so I’d suspect you have an issue where you’re creating thumbs not locally but perhaps on your CDN and then the theme doesn’t know where they are. Or, your setup isn’t configured as to where to create thumbs, and then mod_pagespeed doesn’t know where they are to optimize them, etc.

Seems like you need to go through the steps of researching

theme assets -> CDN/thumbnails
mod_pagespeed <- CDN/thumbnails

Post count: 17

After disabling cdn, theme is creating thumbnails. SO i am going to keep the cdn disabled for images.

Thanks a lot Sir. )

Post count: 9544

<LOL>
welcome to my world; I did the same thing!

I might switch it back on at some point, but right now I found with good optimizations, mod_pagespeed, and decent speed server, the CDN caused more problems. My fave was the CSS not loading for FontAwesome in IE11/Win7-64 totally randomly. (sigh)

Some people have great success with using a CDN, though. It gets even tricker when going to https, which we’re doing now, where you need SSL cert for CDN, wildcard SSL cert for your domain to use a subdomain like cdn.mysite.xyz with A/C name record, and then sharding and/or domain origin mapping with mod_pagespeed …. ouch!

(for those tuning in …. not responsible for your head exploding reading that last paragraph! 🙂 )

Post count: 17

I can totally understand your pain …. https is going to really tricky …. mod_pagespeed and good server has replaced the cdn for now …. have you thought of tuning the responsive side of the theme yet?

Viewing 18 posts - 1 through 18 (of 18 total)
The forum ‘Newspaper’ is closed to new topics and replies.