I use GD to resize image but have some problem when image has white background. If I only upload image and save background is totally white but when resize image it will show multiple white small square in the background
$image = new GD("img/tmp/".$filename);
$image->resize(440, 660);
$image->save("img/original/".$filename, 100);