![]() |
How To Convert a .png Picture Available On My server to jpg using GD and PHP. - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21) +--- Thread: How To Convert a .png Picture Available On My server to jpg using GD and PHP. (/showthread.php?tid=16408) |
How To Convert a .png Picture Available On My server to jpg using GD and PHP. - El Forum - 03-05-2009 [eluser]Unknown[/eluser] Hi, I managed to make upload script for pictures in my server.But now i do not know how to convert that picture from .png to .jpg using php and GD (i do not have imagick installed on the server). Location of picture is in variable $image. Thanks How To Convert a .png Picture Available On My server to jpg using GD and PHP. - El Forum - 03-06-2009 [eluser]pistolPete[/eluser] Use imagecreatefrompng() and imagejpeg(): Code: $im = imagecreatefrompng($png_file_name); |