Image Size issue, 696px thumbnail not used – it's either 640px or full size

Posted in: Newspaper
Post count: 33

Hi there Newspaper team! 🙂

I have a question concerning thumbnail sizes. The post content width is 696px in Newspaper. However, you only get to choose between image widths 640px and Full Size when adding a media.

Bogdan, you wrote in the forum topic https://forum.tagdiv.com/topic/large-image-size-not-reflecting-media-settings/ that the 696px thumb is displayed automatically:

“Add the full width image to your post and the theme will use a thumbnail of 696 pixels which is the max content. It will not add the full image size.”

It doesn’t seem to be true. If you select Full Size when adding a picture, a full size picture will be displayed. Though there seems to be a 696px thumbnail, the post does not use is. Please see the following page i created on my site in order to explain:

http://www.parismalanders.com/test-image-size/

I checked this site from your Showcase to see if my problem was isolated, but it seems there is the same issue:

http://www.gloholiday.com/moving-new-home-sun/

This is I think a very important issue, especially concerning page speed.

Let’s say you upload four amazing pictures 1600*1400 (each 2MB) and insert them into a post in full size. The user will then have to load 8MB to see the four images, instead of the much smaller 696px thumbs. The problems is of course even more important for people using a mobile.

I am struggling with this problem since I use newspaper. I am forced to compress my pictures a lot, in order to obtain reasonable file sizes with bigger pictures (I use 1024 or 1280), which diminishes a lot the quality of the picture.

I’d be happy to hear your thoughts about that! Am I doing something wrong or is there really an issue here?

Best, Roman

  • This topic was modified 9 years by RKdium.
Post count: 171

This has been mising like forever.

Here’s a quick fix, in td_wp_booster_functions.php

Find:
// content width - this is overwritten in post
if ( !isset($content_width) ) {

switch (TD_THEME_NAME) {
case 'Newspaper' :
$content_width = 696;
break;

Replace it with:

// content width - this is overwritten in post
if ( !isset($content_width) ) {

switch (TD_THEME_NAME) {
case 'Newspaper' :
$content_width = 1048;
break;

Post count: 33

Hi Arved,

thanks a lot for your reply!

I tried locating the code. However, i can only find the following strings in td_wp_booster_functions.php:


// content width - this is overwritten in post
if (!isset($content_width)) {
$content_width = 640;
}


switch (TD_THEME_NAME) {
case 'Newspaper' :
$td_temp_image_url = wp_get_attachment_image_src($image_id, 'td_1068x580'); //1021x580 images - for big slide
//change image type and width - used to retrieve retina image
$thumbnail_type = 'td_1068x580';
$thumbnail_width = '1068';
break;


switch (TD_THEME_NAME) {
case 'Newspaper' :
$out['size'] = 'td_1068x580';
break;


switch (TD_THEME_NAME) {
case 'Newspaper' :
$out['size'] = 'td_696x385';
break;

However, none of them matches exactly the ones you posted. The following string is nowhere to be found:


$content_width = 696;

For you information, i am using version 7.8 of the theme.

Maybe you have another idea? Has this been changed in the new version?

Maybe someone from Tagdiv can help?

Thanks a lot!

Post count: 171

My mistake, is 640 not 696 in the original code. :p

Replace:

// content width - this is overwritten in post
if (!isset($content_width)) {
$content_width = 640;
}

With

// content width - this is overwritten in post
if (!isset($content_width)) {
$content_width = 1068;
}

As you can see, the number 640 is the problem,1068 is the real full width of the template, so now you will generate and insert ur images properly.

Try and see if this fix your problem.

Post count: 171

Thou, Newspaper has 696 in the original code if I remember…. well, anaways, tell me if it works. 🙂

Post count: 22421

Hello,
The thumbnail works as expected. Please check any post on our official demo: https://demo.tagdiv.com/newspaper/wordpress-news-magazine-charts-the-most-fashionable-new-york-couples-in-2016/

Please make sure you have the thumbnail enabled from the theme panel: https://www.screencast.com/t/aYxafUODq9

Thanks.

Post count: 33

Hi guys,

thanks to both of you for the replies.

Unfortunately the code solution doesn’t work.

Bogdan, the thumbnail is enabled in the theme panel.

I’ve have checked the post you posted:
https://demo.tagdiv.com/newspaper/wordpress-news-magazine-charts-the-most-fashionable-new-york-couples-in-2016/

It does indeed work for the first picture (the featured image). However the second picture shown on the page (girl doing selfie) is not the 696px thumbnail. It screens the full size picture (900 x 560). Same thing for the fourth picture (greek island view).

Is there any way to show the 696px thumbs or is it just possible with the featured pic?

  • This reply was modified 9 years by RKdium.
Post count: 20688

Hi,

I believe that using such big images in the post content, would not be necessary. The post content width is 696px, so it would be best if you would use images around this size.
Bigger images are not necessary, since they will only be displayed in the post content.
If you would like to use images with bigger sizes or it is necessary, you can try modifying the WordPress thumbnail size
https://www.screencast.com/t/uUqt3tzPh4
Try modifying the medium size for example to a size you want, and then upload a new image in the library, and select the medium size when inserting it in the post content.

Thanks

Post count: 171

For me, this options has never worked.

The big image always gets 640px no matter what size I set in the admin panel. I have to edit the code to get it to work.

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