diff --git a/src/main/php/eu/europa/cedefop/europass/photo.php b/src/main/php/eu/europa/cedefop/europass/photo.php index c138420..30b029a 100644 --- a/src/main/php/eu/europa/cedefop/europass/photo.php +++ b/src/main/php/eu/europa/cedefop/europass/photo.php @@ -40,13 +40,13 @@ fwrite($file,$img_tmp); fclose($file); $image = $upload_path.$ses.'-cv.gif'; - $img = @imagecreatefrompng($image); + $img = @imagecreatefromgif($image); } else if ($photo_type == 'image/png') { $file = fopen($upload_path.$ses.'-cv.png','wb'); fwrite($file,$img_tmp); fclose($file); $image = $upload_path.$ses.'-cv.png'; - $img = @imagecreatefromgif($image); + $img = @imagecreatefrompng($image); } #Resize the image to fit 113x151. @@ -62,4 +62,4 @@ #Destroy the tmp file. imagedestroy($tmp); -?> \ No newline at end of file +?>