1

In a Drupal 7 environment, I want to apply a style to all images within a view. I want every image to be 180px wide & 128px high -OR- 128px wide and 180px high depending on the orientation of the original image.

Can this be done with an image style or do you know any module that would help in achieving this?

2

ImageCache Actions

Aspect Switcher new 2009-08 - lets you perform different actions or use different dimensions based on whether the image is 'landscape' or 'portrait'

3
  • Linking to the official project page for modules is preferred, if possible.
    – mpdonadio
    Jun 15 '12 at 15:14
  • If you end up doing this, make sure you read issues about ImageMagick compatability.
    – mpdonadio
    Jun 15 '12 at 15:14
  • Thanks a lot. One needs to create three image styles, one for landscape, one for portrait and one that is doing the switching action. But it works like a charm.
    – Paul
    Jun 16 '12 at 14:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.