is there a way to rotate a png with gdlib and maintain the transparency of the original image?
this is what i tried ....
$bg = imagecreatefrompng("bg.png");
$img1 = imagecreatefrompng("img1.png");
$img1 = imagerotate($img1,45,IMG_COLOR_TRANSPARENT);
imagecopyresized($img_bg,$img1,0,0,0,0,125,125,125,125);
imagejpeg($img_bg,"./output/output.jpg");
it didn't work. if i take out the rotate line, the resulting image maintains the transparency of the image on top of the background. when it is rotated, the rotated image appears in a black box.
thanks for any help.