• I’ve set up my custom theme with featured images and a specific featured image size all in function.php, and it works great. I set it up in the template to link to the original image file and show the full image using colorbox. But I’d like to be able to upload an image, crop it only for the featured image, so I can roughly center the featured image where I want it and the user can click it and get the full. I have a couple pictures that are longer then wide so I’m getting the center of the image as the featured image and it doesn’t look as nice as it would if I could crop it higher up but only for the featured image.

    Any help, links, plugins, suggestions?

    Thanks

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter mtpultz

    (@mtpultz)

    I’m actually already doing that and it crops it to the dimensions I want for the image but let say the dimensions of the original image is 100×600 (this isn’t actually what it is but trying to emphasis height over width), the crop will be of the center part of the image. So if it was a picture of me head to toe you would get my stomach down to my knees or some variation. I’d like the photo to be uploaded as usual and then be able to crop the feature image only so you get something more like my head to shoulders, then you click and business as usual colorbox opens the larger uncropped image.

    Thread Starter mtpultz

    (@mtpultz)

    So essentially the options available for cropping are “All image sizes”, “Thumbnail”, and ” All sizes except thumbnail”. I want to add another to this list called “Featured”. Crop the image after choosing that radio button and then in my template go:

    if ( has_post_thumbnail() )
    {
        $large_image_url = wp_get_attachment_image_src(get_post_thumbnail_id(), 'large');
        echo '<a href="'.$large_image_url[0].'" class="featured_colorbox" >';
        the_post_thumbnail('featured-thumb');
        echo '</a>';
    }

    Where featured-thumb has already been created in my theme by setting:
    add_image_size( 'featured-thumb', 420, 210, true );

    Thread Starter mtpultz

    (@mtpultz)

    From the WP core it would appear there isn’t a way to change the list to add one more image type like “featured”. So can I assume this is a no go? Is this a good option for a feature in WordPress? Ability to add more then just the thumb to be cropped individually, so when tall images are auto cropped you can avoid it being centred in the wrong spot?

    +1 for this. It would be great to be able to define where the crop is centered. I’ve searched through tons of plugins and I can’t find an acceptable solution.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Are You Able To Crop Just The Featured Image?’ is closed to new replies.