<?php Header ("Content-type", "Text/html;charset=utf-8"); * * Fan Statistics chart */ $image = imagecreatetruecolor (100, 100);/* Create canvas */ /* Set canvas required color */ $white = Imagecolorallocate ($ IMAGE,0XFF,0XFF,0XFF); $gray = imagecolorallocate ($image, 0xc0, 0xc0, 0xc0); $darkgray = imagecolorallocate ($image, 0x90, 0x90, 0x90); $navy = imagecolorallocate ($image, 0x00, 0x00, 0x80); $darknavy = imagecolorallocate ($image, 0x00, 0x00, 0x50); $red = imagecolorallocate ($image, 0xFF, 0x00, 0x00); $darkred = imagecolorallocate ($image, 0x90, 0x00, 0x00); /* Fill background color */ Imagefill ($image, 0, 0, $white); /*3d */ for ($i = $i > $i-) { Imagefilledarc ($image, $i, MB, -160, $darknavy, IM G_arc_pie); Imagefilledarc ($image, $i, M, $darkgray, IMg_arc_pie); Imagefilledarc ($image, $i, M, $darkred, Img_arc_pie); } /* Draw an elliptical arc and populate */ Imagefilledarc ($image, -160, $darknavy, Img_arc_pie); imagefilled Arc ($image, M, M, $darkgray, Img_arc_pie); Imagefilledarc ($image, N, M, $darkred, Img_arc_pie); /* Draw String */ Imagestring ($image, 3, MB, 30%, $white); Imagestring ($image, 3,,, 60%, $whit e); Imagestring ($image, 3, (), "10%", $white); /* Output image */ Header ("Content-type:image/png"); Imagepng ($image); /* FREE resources */ Imagedestroy ($image); ? |