marshsu / timthumb

Automatically exported from code.google.com/p/timthumb
0 stars 0 forks source link

Add "max" value to "h" and "w" settings #482

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Crop image to X px wide and default (100%) image height.
Allows turning image into horizontally repeated background.

As setting if could accept i.e. w=1&h=max
I did that by adding this on line 563

if ($this->param('h', 0) == "max") $new_height = (int) imagesy ($image);  

If could be done for vertical too.

Original issue reported on code.google.com by tomek.ci...@webanywhere.co.uk on 14 Apr 2014 at 9:03