Dl functions will not use & lt ;? Phpheader (& quot; Content-type: imagepng & quot;); dl (& quot; php_gd2.dll & quot;); $ im @ imagecreate (100,50) & nbsp; ordie (& quot; CannotInitializenewGDimagestream & quo dl function not used
Header ("Content-type: image/png ");
Dl ("php_gd2.dll ");
$ Im = @ imagecreate (100, 50)
Or die ("Cannot Initialize new GD image stream ");
$ Background_color = imagecolorallocate ($ instant, 255,255,255 );
$ Text_color = imagecolorallocate ($ im, 233, 14, 91 );
Imagestring ($ im, 1, 5, 5, "A Simple Text String", $ text_color );
Imagepng ($ im );
Imagedestroy ($ im );
?>
The example does not need to be suspected. if you copy it in the manual, close the gd2 extension. I added a sentence dl ("php_gd2.dll"), which does not work, whether it is. /.. /ext or all paths do not work. why ???
------ Solution --------------------
First of all, I do not know the server that the main user uses. if it is linux, it will not use dll, but so
Secondly, dl functions do not support multi-threaded web servers. Therefore, apache with dl must be configured as the prefork working mode.
We do not recommend using the dl function at last. you can configure the extension directly.
------ Solution --------------------
The manual provides the following examples:
PHP code
------ Solution --------------------
Better written to php. ini
5.3 dl functions are not supported!
Win is. dll
Linux is. so