PHP and class.graph problem

From: Date: Fri, 30 Jul 1999 09:25:56 +0000
Subject: PHP and class.graph problem
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-9342@lists.php.net to get a copy of this message
Hi PHP-DEVelopers, I use the class.graph " Version 1.0Beta, Revision 2 from Valuehunt Inc." (wonderful and powerful class :) with PHP 3.0.11 . When I create ONE graph, everything works correctly, but when I try to put more than 4 graphes (not a mixed chart, but different gifs), it doesn't work anymore correctly :( Here is what I try to do : <<<< while ( $row = mysql_fetch_array( $queryResult) ) # in order to contruct a gif for EACH row of the queryResult (mySql) { phpplot(...); phpdata($myData); phpdraw(bargraph, ...) ; $gifFile = tempnam ("gif","gif"); $gifFile = $gifFile.".gif" ; phpshow($gifFile) ; print ("<BR><IMG src=\"$gifFile\">"); } >>>> I'm a novice in PHP3 and so maybe do I a 'big' mistake ... But when I launch this script with more than 4 gif to display, PHP returns this error under the 4th graph .. : <<<< Fatal error: Unable to initialize a new token cache in class.graph on line 588 >>>> And the line 588 is : <<<< if(is_array($a)) { while(list($k,$v) = each($a)) { eval( "\$this->".$k." = \$v ;"); # line 588 } } >>>> Has anyone a solution to this problem ? Thanx, David.

« previous php.dev (#9342) next »