PHP Source Code of /bar.php3 -------------------------------------------------------------------------------- Last Modified: 09:30 AM 07/06/1999 Print Date: 03:19 AM 07/12/1999 Size: 1163 -------------------------------------------------------------------------------- Date: 3/31/1999 Desc: Creates a gradient fill Parm: h= height of graphic w= width of graphic textmsg= is the text you wish to display (does not allow wrapping) textsz= is the size of the text Example: http://192.168.98.100/php/bar2.php3?h=300&w=500&textmsg=Hello+World&textsz=3 */ $image1=0; $y=0; $z=0; $white=0; if (!(isset($h))) $h=30; if (!(isset($w))) $w=30; if (!(isset($textsz))) $textsz=2; $image1=imagecreate($w,$h); //Set the colors for used in image1 $white=imagecolorallocate($image1,255,255,255); $red=imagecolorallocate($image1,255,0,0); $blue=imagecolorallocate($image1,0,0,255); $colorfac=(255/$h); for ($i=1; $i<=$h; $i++) { $color=imagecolorallocate($image1,0,0,$i*$colorfac); imageline($image1,0,$i,500,$i,$color); } if (isset($textmsg)) imagestring($image1,$textsz, 10,10,$textmsg,$white); //Send the image to the client $z=ImageGif($image1); //imagegif($image1,"/home/httpd/html/bar1.gif"); ImageDestroy($image1); ?> -------------------------------------------------------------------------------- The syntax highlighted source is automatically generated by PHP from the plaintext script. If you want to see the source of source.php3, have a look here.