View file blog/grafic.php

File size: 686B
<?
#-----------------------------------------------#
#             	?uthor:  Nu3oN                  #
#                  ICQ : 100-50-97              #
#-----------------------------------------------#
$_per = isset($_GET['percent']) ? (int)$_GET['percent'] : 0;
if ($_per == '100') $_per = $_per-2; elseif($_per == '99') $_per = $_per-1;

header("Content-type: image/gif");

$image = imagecreatefromgif('images/grafic.gif');
$_lineC = imagecolorallocate($image, 204, 204, 204);
$_textC = imagecolorallocate($image, 0, 0, 0);

if ($_per > 0) imagefilledrectangle ($image, 1, 8, $_per, 1, $_lineC);

imagestring($image, 1, 80, 1, $_per, $_textC);
imagegif($image);
?>