PHP5中GD2函数库提供了强大的绘图功能。 安装完PHP后可以在浏览器的地址栏输入“http://127.0.0.1:端口号/phpinfo.php”, 按住回车键就可以检索到GD库的安装信息。 首先来演示一段代码 <?php header("Content-type:image/png"); $img=imagecreate(200, 200); $bg=imagecolorallocate($img, 12, 135, 20); $white=imagecolorallocate($img, 255, 255, 255); imagearc($img,100,100,150,150,0,360,$white); imagepng($img); imagedestroy($img); ?> 这是首先创建一个200X200的画布,并在画布上画了一个圆。
PHP的GD库绘图
原创
©著作权归作者所有:来自51CTO博客作者寂岚峰的原创作品,请联系作者获取转载授权,否则将追究法律责任
提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章