Bonjour,
j'ai le code suivant
et............page blanche
Code : Sélectionner tout - Visualiser dans une fenêtre à part
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 <?php require_once "../ScatterPlot.class.php"; $connect = pg_connect("host=localhost port=5432 dbname=*** user=*** password=***"); $result = pg_query($connect, "SELECT mois, round FROM view_moy_labo"); $datax = array(); $datay = array(); while ($row=pg_fetch_array($result)) { array_push($datax, $row['mois']); array_push($datay, $row['round']); } print_r ($datax); print_r ($datay); $graph = new Graph(400, 400); $graph->title->set('Simple ScatterPlot'); $y = array($datay); $x = array($datax); $plot = new ScatterPlot($y, $x); $plot->setBackgroundColor(new VeryLightGray); $plot->setPadding(NULL, NULL, 40, 20); $plot->legend->add($plot, 'Some points', Legend::MARKONLY); $graph->add($plot); $graph->draw(); ?>
l'exécution du script ne génère pas d'erreur mais absolument rien à l'écran
Séparément, je suis sûr que la requête marche, que le graph d'artichow aussi; mais les 2 ensemble ça ne fonctionne pas!!
Merci de votre aide
Partager