Another thing I think we do very well in the CultureMap code is cropping. Since we are very image heavy, we have many crops. We have a lot of party photos with women wearing gowns and such. When we first launched, the automatic crops a lot of times would center on their chests to put it nicely :-). So while most of time the automatic crops of Sorl were great, we needed a way to override them. So we came up with crop overrides.
Each image has three image overrides:
- Square Crop
- Landscape Crop
- Portrait Crop
Lets take the square crop for example. If no crop image is uploaded then a square crop is generated from the original. If a square crop image does exist then that is used instead to generate the crop. This feature gives you the ability have automatic crops most of the time, but also easily change the crop if something embarrassing occurs.
Everything is done through additional image fields on the image model and a template tag like such:
{% crop_override image "square" im %}
<img src="{{ im.url }}" title="" alt=""/>
{% endcrop_override %}
Additionally we hooked up
picnik.com so that a crop could be created from the Admin CMS with a few clicks.
Our editorial team loves this feature, so if you would like me to contribute it to Armstrong just let me know.