function imagecreatefrombmp($filename) { $tmp_name = tempnam("/tmp", "GD"); if (ConvertBMP2GD($filename, $tmp_name)) { $img = imagecreatefromgd($tmp_name); unlink($tmp_name); return $img; } return false; }
function imagecreatefrombmp($filename) { global $uploadpath; $tmp_name = tempnam($uploadpath, "GD"); if (ConvertBMP2GD($filename, $tmp_name)) { $img = imagecreatefromgd($tmp_name); unlink($tmp_name); return $img; } return false; }