Title: Variable Image Heights?
Last modified: August 20, 2016

---

# Variable Image Heights?

 *  Resolved [CowboyFrank](https://wordpress.org/support/users/cowboyfrank/)
 * (@cowboyfrank)
 * [14 years, 10 months ago](https://wordpress.org/support/topic/variable-image-heights/)
 * My post thumbnails are a mix of portrait (vertically oriented) and landscape (
   horizontally oriented) images. If I specify an image height in the carousel settings,
   the landscape images get stretched. If I leave the image height blank, the portrait
   images get squashed to the height of the shortest landscape image. Is there a
   way to configure the carousel to keep a fixed image width for each slide, but
   allow the heights of the images to vary according to their orientation?
 * Thanks!

Viewing 1 replies (of 1 total)

 *  Thread Starter [CowboyFrank](https://wordpress.org/support/users/cowboyfrank/)
 * (@cowboyfrank)
 * [14 years, 10 months ago](https://wordpress.org/support/topic/variable-image-heights/#post-2206113)
 * Just figured out my own problem: leave the image height blank in the Carousel
   settings, and in theme.php, change:
 *     ```
       if (!$config['HAS_IMG_HEIGHT'])
       	{
       		$config['IMG_HEIGHT'] = '100px';
       ```
   
 * to
 *     ```
       if (!$config['HAS_IMG_HEIGHT'])
       	{
       		$config['IMG_HEIGHT'] = '';'
       ```
   
 * Voila!

Viewing 1 replies (of 1 total)

The topic ‘Variable Image Heights?’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-carousel.svg)
 * [WP Carousel](https://wordpress.org/plugins/wp-carousel/)
 * [Support Threads](https://wordpress.org/support/plugin/wp-carousel/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-carousel/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-carousel/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-carousel/reviews/)

 * 1 reply
 * 1 participant
 * Last reply from: [CowboyFrank](https://wordpress.org/support/users/cowboyfrank/)
 * Last activity: [14 years, 10 months ago](https://wordpress.org/support/topic/variable-image-heights/#post-2206113)
 * Status: resolved