humanmade / WPThumb

:warning: UNMAINTAINED :warning: On demand image resizing for WordPress
https://humanmade.co.uk/wpthumb/
170 stars 32 forks source link

How to use filter #53

Closed Colir closed 11 years ago

Colir commented 11 years ago

Hi i try to archive this effect usign the phpThumb lib http://phpthumb.sourceforge.net/demo/demo/phpThumb.demo.demo.php#x29

How to do this ?

i use this code <?php the_post_thumbnail(array('width' => 202, 'height' => 120, 'crop'=>'true')); ?>

thanks

Colir commented 11 years ago

no idea ? thanks

joehoyle commented 11 years ago

Hi @colir sorry for the delay. You add any filters, you will want to hook into the wpthumb_image_post hook, similar to how the watermarking does this here: https://github.com/humanmade/WPThumb/blob/master/wpthumb.watermark.php#L104

Let me know if you have any more questions, I will do a write up on customizing the image via filters in the wiki at some point too!