Pyh.conf’25: a new PHP conference for the Russian-speaking community

Voting

: max(nine, three)?
(Example: nine)

The Note You're Voting On

aaron at aaron-wright dot com
22 years ago
Actually GD <2.0 had imagecreattruecolor, it just didn't work :P

This is a better test:

function chkgd2(){
$testGD = get_extension_funcs("gd"); // Grab function list
if (!$testGD){ echo "GD not even installed."; exit; }
if (in_array ("imagegd2",$testGD)) $gd_version = "<2"; // Check
if ($gd_version == "<2") return false; else return true;
}

if (chkgd2()) echo "<h1>GD2+ is installed.</h1>"; // Test for GD2
else echo "<h1>GD2+ is not installed.</h1>";

<< Back to user notes page

To Top