Title: Size images
Last modified: March 24, 2020

---

# Size images

 *  Resolved [doomidze](https://wordpress.org/support/users/doomidze/)
 * (@doomidze)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/size-images/)
 * Hello. I set the custom thumbnail size for my images but not shows right size
   [http://prntscr.com/rm39jx](http://prntscr.com/rm39jx) . It added only inline
   styles. I need to show images with less size (292×140). I receiving right sizes
   only with removing ‘scan_images’ parameter, but I’m not sure that it is good 
   idea [http://prntscr.com/rm3for](http://prntscr.com/rm3for) . Also I’m adding‘
   thumb_size’ and add_image_size($size) but without success.

Viewing 12 replies - 1 through 12 (of 12 total)

 *  Plugin Author [Ajay](https://wordpress.org/support/users/ajay/)
 * (@ajay)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/size-images/#post-12584477)
 * Few things to check:
    1. What is the settings page for CRP have for the thumbnail
   size and have you activated the crop settings and also the crp_thumbnail?
 * 2. You can try installing [https://wordpress.org/plugins/otf-regenerate-thumbnails/](https://wordpress.org/plugins/otf-regenerate-thumbnails/)
   This hasn’t been updated for a while but has worked with the last few versions.
   
   Alternatively just regenerate all thumbnails with [https://wordpress.org/plugins/regenerate-thumbnails/](https://wordpress.org/plugins/regenerate-thumbnails/)
 * 3. Can you check that the thumbnails actually exist?
 *  Thread Starter [doomidze](https://wordpress.org/support/users/doomidze/)
 * (@doomidze)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/size-images/#post-12584540)
 * I tried to fix it and even when I removing ‘scan_images’ parameter – it is not
   working (still large images)
    I activated the crop settings – not working I created
   new media size [https://prnt.sc/rmtd7u](https://prnt.sc/rmtd7u), tried with cropping
   and without – not working. I’m using Regenerate Thumbnails plugin and it creates
   needed size of images [https://prnt.sc/rmtfte](https://prnt.sc/rmtfte)
 *  Plugin Author [Ajay](https://wordpress.org/support/users/ajay/)
 * (@ajay)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/size-images/#post-12586573)
 * Could you please turn on crop mode as well in your settings so the exact image
   size gets created?
 * The rest of the settings look fine.
 * And looks like your images are also there properly. Do you also have the image
   from [https://prnt.sc/rm39jx](https://prnt.sc/rm39jx) created in the size?
 *  Thread Starter [doomidze](https://wordpress.org/support/users/doomidze/)
 * (@doomidze)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/size-images/#post-12586620)
 * Still no
    [https://prnt.sc/rn4xjp](https://prnt.sc/rn4xjp) – crop mode [https://prnt.sc/rn4zrx](https://prnt.sc/rn4zrx)–
   image [https://prnt.sc/rn4w8k](https://prnt.sc/rn4w8k) – result [https://prnt.sc/rn55t4](https://prnt.sc/rn55t4)
   $output .= zerif_list_link( $args, $result ); Other settings works fine
    -  This reply was modified 6 years, 2 months ago by [doomidze](https://wordpress.org/support/users/doomidze/).
    -  This reply was modified 6 years, 2 months ago by [doomidze](https://wordpress.org/support/users/doomidze/).
 *  Plugin Author [Ajay](https://wordpress.org/support/users/ajay/)
 * (@ajay)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/size-images/#post-12611700)
 * What is the function “zerif_list_link”? Is this being bundled into Zerif? And,
   if so is this the latest version?
 * If not, can you disable whatever is via Zerif and instead use the latest version
   of Contextual Related Posts repository?
 * I’m not sure if this is an issue but want to eliminate if that is the case.
 * I think there might be a bit of debugging needed as I’m quite lost as to why.
 * Looking at that specific image, this is being pulled up because the “scan images”
   which is the same as the Extract First Image setting (in your screenshot above)
   is enabled.
 * This is the piece of code: [https://github.com/WebberZone/contextual-related-posts/blob/v2.8.0/includes/media.php#L113-L142](https://github.com/WebberZone/contextual-related-posts/blob/v2.8.0/includes/media.php#L113-L142)
 * The plugin first extracts the image and then attempts to get the [correct size](https://github.com/WebberZone/contextual-related-posts/blob/v2.8.0/includes/media.php#L135)
 * This looks like it needs a lot more debugging, but two things as a workaround–
   you can use a featured image when saving the posts which will automatically use
   that first vs trying to extract an image.
    The other option is to disable uncheck
   the setting to extract the first image
 *  Plugin Author [Ajay](https://wordpress.org/support/users/ajay/)
 * (@ajay)
 * [6 years, 2 months ago](https://wordpress.org/support/topic/size-images/#post-12628490)
 * I’ve been doing more testing with this and I realised the reason why this is 
   likely not working and involves the way the plugin tries to guess the correct
   size when it extracts the first image in the post.
 * [This line](https://github.com/WebberZone/contextual-related-posts/blob/v2.8.0/includes/media.php#L133)
   attempts to find the ID of the image/attachment and then find the correct size.
   Looking at your screenshot, the image has a relative link starting with / instead
   of your full image URL including your domain. As a result of this, it cannot 
   find the image ID and consequently can’t find the correct size for the image.
 * One way to try to fix that is to use the full image URL including your domain–
   although the featured image approach will be the better option as per my previous
   post.
 *  Thread Starter [doomidze](https://wordpress.org/support/users/doomidze/)
 * (@doomidze)
 * [6 years ago](https://wordpress.org/support/topic/size-images/#post-12860766)
 * Thank you for your answer Ajay.
    Yeah, I can imagine the problem. My custom output
   for image now is a crp_list_link function. I don’t know how I can replace an 
   image. Without my custom output works well.
 * I can delete my output but I need to customize my output. Just replace the structure:
   wrap an image in new div, replace title, add a permalink to title.
    I saw the
   api file [https://github.com/WebberZone/code-library/blob/master/contextual-related-posts/crp-api-example.php](https://github.com/WebberZone/code-library/blob/master/contextual-related-posts/crp-api-example.php)
   but I can’t figure out how to solve my problem. Only replacing will be enough.
 *  Plugin Author [Ajay](https://wordpress.org/support/users/ajay/)
 * (@ajay)
 * [6 years ago](https://wordpress.org/support/topic/size-images/#post-12863203)
 * I’ve made some changes to the way the plugin looks at thumbnails, including some
   extra checks – but I’m not sure if this fixes your problem. Have you had a chance
   to test with v2.9.2?
 * I don’t think using the API to get your own custom output would help – it might
   be easier to disable “Get first image” in [Thumbnail settings](https://ps.w.org/contextual-related-posts/assets/screenshot-4.png?rev=2061733)
   and see what the outputs are.
 *  Thread Starter [doomidze](https://wordpress.org/support/users/doomidze/)
 * (@doomidze)
 * [6 years ago](https://wordpress.org/support/topic/size-images/#post-12863832)
 * I’m using Version 2.9.2
    With disabling “Get first image” works well but I really
   need “Get first image” because I have many posts with it.
 *  Plugin Author [Ajay](https://wordpress.org/support/users/ajay/)
 * (@ajay)
 * [6 years ago](https://wordpress.org/support/topic/size-images/#post-12871243)
 * I’m not sure how exactly to get this dynamic given the relative paths which doesn’t
   allow the plugin to find the right size.
 * Two options I can think of given your install:
    1. [https://hexadix.com/wordpress-auto-set-featured-image-using-first-image-post/](https://hexadix.com/wordpress-auto-set-featured-image-using-first-image-post/)
   set the first image as a featured image
 * 2. Do a find and replace in the DB to replace your partial URLs `"/` with your`
   example.com/` so that the plugin can attempt to trace this. Obviously, please
   only use this on a test install and sufficiently backup
 *  Thread Starter [doomidze](https://wordpress.org/support/users/doomidze/)
 * (@doomidze)
 * [6 years ago](https://wordpress.org/support/topic/size-images/#post-12877913)
 * Thank you Ajay.
    Unfotunatelly I haven’t PayPal to buy you a cofee
 *  Plugin Author [Ajay](https://wordpress.org/support/users/ajay/)
 * (@ajay)
 * [6 years ago](https://wordpress.org/support/topic/size-images/#post-12881409)
 * No problem at all! Thank you for the review.

Viewing 12 replies - 1 through 12 (of 12 total)

The topic ‘Size images’ is closed to new replies.

 * ![](https://ps.w.org/contextual-related-posts/assets/icon-256x256.png?rev=2985705)
 * [Contextual Related Posts](https://wordpress.org/plugins/contextual-related-posts/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/contextual-related-posts/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/contextual-related-posts/)
 * [Active Topics](https://wordpress.org/support/plugin/contextual-related-posts/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/contextual-related-posts/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/contextual-related-posts/reviews/)

 * 12 replies
 * 2 participants
 * Last reply from: [Ajay](https://wordpress.org/support/users/ajay/)
 * Last activity: [6 years ago](https://wordpress.org/support/topic/size-images/#post-12881409)
 * Status: resolved