Variables
$svgwidth=800;
$svgheight=400;
$graphheight = 300;
$graphwidth = 750;
$margin = 20;
$scaleSize = 125; //Minimum value on Y-axis - use round numbers!
$minScaleCount = 5; //Maximum number of valuespoints on Y-axis
//serie colors
$serieAColor = 'green';
$serieBColor = 'orange';
$serieCColor = 'blue';
$serieDColor = 'purple';
$serieEColor = 'red';
$serieFColor = 'yellow';
$serieGColor = 'navy';
$serieHColor = 'gray';
$serieIColor = 'black';
$serieJColor = 'pink';
Parameter passing
/*
series are defined in the values of serieA=NAME... example:
serieA=redhat
serieB=mandrake
serieC=turbo
the serievalues are then defined like NAME.N=VALUE. Where the first value of N = startDate... example:
startDate=1
endDate=3
redhat1=225
redhat2=325
redhat3=1256
mandrake3=556
store these parameters in a variable like this:
$parameters = "?startMonth=1&endMonth=3&startYear=2002&serieA=redhat&serieB=mandrake";
$parameters .= "&redhat1=333&redhat2=444&mandrake1=0&mandrake2=555&mandrake3=666";
note that empty field should be written as zero
Usually a graph will be embedded in a another webpage. Do it like this: