syntax error, unexpected '['
bonjour
please ce fichier de graphe il m'affiche cette erreur mais je ne l'ai pas trouvé cette erreurarse error:
Citation:
syntax error, unexpected '[' in C:\Program Files\EasyPHP-5.3.9\www\psycho\statisrique\stat_lycee\statq011.php on line 28
fichier.php
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45
| <?php header("Content-type: image/png");
$con=mysql_connect("localhost","root","");
if ($con==FALSE)
die("réssayez");
include ('../gg/src/jpgraph.php');
include ('../gg/src/jpgraph_pie.php');
$db1=mysql_select_db("programme");
$pass=$_POST['pass'];
$wilaya=$_POST['wilaya2'];
$lycee=$_POST['lycee2'];
$req3="SELECT * FROM lycee where LYCEE='$lycee' ";
$res3=mysql_query($req3);
if($res3==false)
{echo mysql_error();die();}
$line=mysql_fetch_array($res3);
$id=$line['ID'];
$nom_lycee=$line['LYCEE'];
$wilaya=$line['WILAYA'];
$id_wilaya=$line['CDE'];
$req_r6="SELECT * FROM q01 ";
$res_r6=mysql_query($req_r6);
if($res_r6==false)
{echo mysql_error();die();}
$rep = array();
$l1 = array();
while ($line_r6=mysql_fetch_array($res_r6))
{
echo'eeeee';
$rep[] = line_r6['nombre']; //ici la ligne d'erreur
$l1[] = line_r6['L1'];
}
die();
//$data=array(4,8,9);
$p = new PiePlot($rep);
$p->SetLabelType(PIE_VALUE_ADJPER);
$p->value->SetFormat('%d');
$p->SetGuideLines();
$p->SetLegends($l1);
//$p->value->SetFormat('%d ventes');
$p->ExplodeSlice(1); // fait resortir la 2e part
$g = new PieGraph(400, 400);
$g->title->Set("pourcentage des réponses");
$g->Add($p);
$g->Stroke();
?> |