RIP - IE

Using ImageMagick & PHP to Resize / Crop Images to flickr style squares.

March 24th 2008

Here is a quick snippet of code I use frequently to get the flickr style square cropped thumbnails using php and imagemagick.


<?php

function sqThm($src,$dest,$size=75){
   
   list($w,$h) = getimagesize($src);

   if($w > $h){
      exec("convert ".$src." -resize x".$size." -quality 100 ".$dest);
   }else{
      exec("convert ".$src." -resize ".$size." -quality 100 ".$dest);
   }

   exec("convert ".$dest." -gravity Center -crop ".$size."x".$size."+0+0 ".$dest);

}

sqThm('gfx/tree.jpg','gfx/tree_squared.jpg');

?>

1,763 downloads

8 Comments

Albuquerque Balloon Festival   

October 7th 2007

Its been quite some time since I have been to the balloon festival. I figured its time to give it a try again. It really was a good time, even though waiting in traffic at 5 am for about an hour it was worth it.

1 Comment

Amazing Google Widget

June 4th 2007

The amazing google widget is all you need for your google searching. Quick and easy searching right at your fingertips. We will be rapidly developing this widget further to make the most useful google tool possible. You can search the following with this widget:

  • web
  • images
  • video
  • news
  • maps
  • blogs

Give it a try and see what you think.

12,046 downloads

1 Comment

Joe Calendar

May 5th 2007

Tired of bloated calendar programs? Too many features your never going to use? Try this simple calendar system. Packed together with simplicity in mind, you can stylize the way the calendar feeds the content using CSS. Along with a backend using AJAX technologies. It doesn’t get any easier than this.

1,984 downloads

22 Comments

Vegas 2007   

February 10th 2007

It was a great trip to Vegas with the weather being a relief compared to the freezing cold back home. Vegas is just an amazing city, there is so much money flowing through that place it is unreal. There is nothing like a touch of every city around the world placed in the middle of the desert.

Vegas Baby!

1 Comment

1 2 3 4 5 6 7 8 9