Articles of set post thumbnail size

Is it possible to preserve original images in order to change image size later?

I want to create a simple wordpress blog site. At the moment I will use a template, but I would like to develop my own afterwards. And I have one concern related to images. Current template has nice big images and no sidebar, but in my future template I will definitely have a sidebar, which […]

How can i make this in the_post_thumbnail?

if I add this code in my theme function.php add_image_size(‘thumb’ , 130, 65, true ); // Thumb add_image_size(‘max’ , 610, 305, true ); // Maximum add_image_size(‘min’ , 270, 135, true ); // Minimum …the file names of uploaded images is: photo-name-130×65.jpg photo-name-610×305.jpg photo-name-270×135.jpg photo-name.jpg How can I rename them to the following (by default)? photo-name-thumb.jpg […]

How to set post thumbnail size?

I want to smaller my post thumbnails from 825px to something like 150×150. I’m using the newest version of wordpress and the “sark press” theme. So this is my code: sarkpress-function.php <?php function sarkpress_render_post_thumbnail() { if ( post_password_required() || ! has_post_thumbnail() ) { return; } if ( is_singular() ) : ?> <div class=”post-thumbnail” itemprop=”thumbnail”> <?php […]

Fit image to Thumbnail canvas size

I need to upload images with differrent orientation (portrait and landscape) and I don’t want to crop post-thumbnails. But I need always thumbnail size 250x250px. If I upload portrait oriented image – it will be resized to 250px height, but width may me different. And conversely – if I load landscape oriented image – it […]

Set Post Thumbnails in Percents

I’ve built this responsive site on WordPress and got a little curious as to how I can set the post thumbnails in percentages. Any help would be much appreciated.

the_post_thumbnail() Custom sizes not display correctly

I’m trying to display wide image icons from the_post_thumbnail() function. I’m using ‘true’ value for cropping, but they are not cropped well… I get some strange results with different sizes (I’m trying to use 200width x 150height). If image cannot be display with good proportions (I don’t know why whem I’m cropping it? ) then […]

WordPress fails to auto crop featured images

I set 2 crop sizes in the functions.php file. // Setup Post Thumbnails // ———————————————– add_theme_support(‘post-thumbnails’); add_image_size(‘imagePost-thumb’, 970, 9999,false); add_image_size(‘better-thumb’, 200, 9999, false); Then in the appropriate loops we pull one of the thumbnails based on post type. <?php if ( has_post_thumbnail() ): ?> <?php $size = (get_post_type() == ‘imagepost’) ? ‘imagePost-thumb’ : ‘better-thumb’; ?> […]

post_thumbnail_html only for specific thumb size

I’v created a custom thumbnail size (in my function.php) called ‘thumb-bookmark’ and wanted to add a permalink to all of them but I don’t know how to target only this specific size with this code: function thumb_bookmark_html( $html, $post_id, $post_image_id, $size ) { $html = ‘<a class=”MyClass” href=”‘ . get_permalink( $post_id ) . ‘” alt=”‘ […]

Custom Image Thumbnails of Different Sizes

I have a Custom Post Type which contains custom fields for uploading images of different types for a portfolio site. For example: (logos, websites, print-ads, etc…). I plan on uploading images of all different sizes and aspect ratios, but I need to have a smaller size (thumbnail) of a specific (and different) size for each […]

set_post_thumbnail_size not cropping featured images, but reducing proportionally

In my function file, I set the following: if ( function_exists( ‘add_theme_support’ ) ) { add_theme_support( ‘post-thumbnails’ ); set_post_thumbnail_size( 150, 50, true ); } And in the loop: <?php the_post_thumbnail(); ?> But the images are resized proportionally, using the smallest value. The crop is not working. UPDATE I change the function: function resize_thumb () { […]