My favorites | Sign in
Project Home Downloads Wiki Issues Source
Project Information
Members
Links

I've found a good (probably better) alternative, so if my plugin doesn't work for you, check out imgLiquid!


Resize & Crop

Handy jQuery plugin for client-side uniform resizing & cropping. Ideal for avatars and images with similar size (more different sizes—the bigger bandwidth overhead).

Ideal use

You can use plugin for example to transform profile pictures of Facebook users (profile avatars). They are similar in size but not the same, but if you want to show them in a grid you probably want them to be same height (or/and width).

See example with cats to get better understanding what Resize & Crop can do for you.


Example how Resize & Crop works:


Code example:

<script src="js/jquery.resizecrop.js"></script>
<script>
  
  $(document).ready(function(){
    $('img').resizecrop({
      width:40,
      height:60,
      vertical:"top"
    });  
  });  

</script>

Note:

If the image looks awful in IE6-7 try to use this little CSS snippet for better Bicubic Scaling:

img { -ms-interpolation-mode: bicubic; }
Powered by Google Project Hosting