I am new to image creation in php.
If you change the param value, bar progress should also be changed to passed value
How can i implement something like that?
I would be grateful if anyone can shed some light
Thanks for the help inadvance
UPDATE: I figured it out myself, thank you Greg and all for the suggestions ... please test this code
<?php
header("Content-type: image/png");
$p = $_GET['percentage']; //(e.g. 20);
$w = 50;
$h = 100;
$nh = $h - ($h*$p)/100;
$im = imagecreatetruecolor($w, $h);
$color1 = imagecolorallocate($im, 238,236,224);
$color2 = imagecolorallocate($im, 201,216,209);
//background
imagefilledrectangle($im, 0, 0, $w, $h, $color1);
//front
imagefilledrectangle($im, 0, $nh, $w, $h, $color2);
//output the image
imagepng($im);
imagedestroy($im);
?>