I am trying to dynamically produce a graph (using jp graph) from a database.
Getting the information from the database is not the problem.
This is where I am at the moment
I am getting the following message on screen
array(0,0,0,0,0,0,0,0,0,839,762,769,690,530,517,450,297,9,0,0,0,0,0,0);JpGraph Error Either X or Y data arrays contains non-numeric values. Check that the data is really specified as numeric data and not as strings. It is an error to specify data for example as '-2345.2' (using quotes).
Thanking in advance for any help received
Getting the information from the database is not the problem.
This is where I am at the moment
Code:
//This line simulates info from the database
$xaxis="0,0,0,0,0,0,0,0,0,839,762,769,690,530,517,450,297,9,0,0,0,0,0,0";
//To work properly this is how it must appear
//$data1y=array(0,0,0,0,0,0,0,0,0,839,762,769,690,530,517,450,297,9,0,0,0,0,0,0);
$test="array(".$xaxis.");";
eval("\$test = \"$test\";");
$data1y=$test;
array(0,0,0,0,0,0,0,0,0,839,762,769,690,530,517,450,297,9,0,0,0,0,0,0);JpGraph Error Either X or Y data arrays contains non-numeric values. Check that the data is really specified as numeric data and not as strings. It is an error to specify data for example as '-2345.2' (using quotes).
Thanking in advance for any help received