If you want to open a png image with alpha blending, you need to do something like this:
<?php
$file = 'semitransparent.png'; // path to png image
$img = imagecreatefrompng($file); // open image
imagealphablending($img, true); // setting alpha blending on
imagesavealpha($img, true); // save alphablending setting (important)
?>
I spent almost a day to find out why alpha blending doesn't work. I hope this is usefull to others too :)