Bonjour,

Voici une question de cours.

Pouvez m'expliquer un petit peu comment se déroule une procédure d'affichage d'une page internet lors du chargement (page d'accueil en .html avec une page .php qui contient des fonctions à executer dans la page principale ....
Vous m'avez compris ou je la refait ??

En fait le but de cette question est le suivant :
Mon architecture est une page principale en html qui appel des fonctions qui sont sur une autre page php. Lorsque ces fonctions revoient des chaines de charactères qui vont une fois transmis sur la page htlm former un formulaire par exemple ça :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
 
echo '<li';
echo ($select);
echo "><a href=\"sitesel1.php\"><span>Site Selection I</span></a></li>";
echo "<li";
if (preg_match("#sitesel2.php#", $this->URI)){echo "id =\"current\"";}else{echo "";}
echo "><a href=\"sitesel2.php\"><span>Site selection II</span></a></li>";
echo "<li><a href=\"timeline.php\"><span>MCP Timeline</span></a></li>";
echo "<li><a href=\"paramsetup.php\"><span>MCP Parameters setup</span></a></li>";
Cela MARCHE !! Ok

MAIS si dans la page htlm je mets un code php qui possède un appel à une fonction php de l'autre page contenant les fonctions par exemple :
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<div id="graphCorelMet6">
			<?php 
			include_once ("graph-jpgraph/src/jpgraph.php");
			include_once ("graph-jpgraph/src/jpgraph_gantt.php");

			$graph = new GanttGraph();
			$graph->title->Set("Using the builtin icons");

			$graph->SetDateRange('2000-10-06','2002-4-10');


			$graph->SetVMarginFactor(1.5);

			$graph->SetMarginColor('lightgreen@0.8');
			$graph->SetBox(true,'yellow:0.6',2);
			$graph->SetFrame(true,'darkgreen',4);
			$graph->scale->divider->SetColor('yellow:0.6');
			$graph->scale->dividerh->SetColor('yellow:0.6');

			$graph->ShowHeaders(GANTT_HMONTH | GANTT_HYEAR);
			$graph->scale->month->grid->SetColor('gray');
			$graph->scale->month->grid->Show(true);
			$graph->scale->year->grid->SetColor('gray');
			$graph->scale->year->grid->Show(true);

			$graph->scale->actinfo->SetColTitles(
			    array('Note','Task','Duration','Start','Finish'),array(20,50,20));
			$graph->scale->actinfo->SetBackgroundColor('green:0.5@0.5');
			$graph->scale->actinfo->SetFont(FF_ARIAL,FS_NORMAL,10);
			$graph->scale->actinfo->vgrid->SetStyle('solid');
			$graph->scale->actinfo->vgrid->SetColor('gray');


			$erricon = new IconImage(GICON_FOLDER,0.6);
			$startconicon = new IconImage(GICON_FOLDEROPEN,0.6);
			$endconicon = new IconImage(GICON_TEXTIMPORTANT,0.5);

			$countMet = $connexion->numberMetStat();
			
			$data = array();
			for($i=0; $i<$countMet; $i++)
			{
				$data[$i] = array($i,array($erricon,"Pre-study","102 days","23 Nov 01","1 Mar 02")
				      , "2001-11-23","2002-03-1",FF_ARIAL,FS_NORMAL,8);
			}
			
			
			for($i=0; $i<count($data); ++$i) {
				$bar = new GanttBar($data[$i][0],$data[$i][1],$data[$i][2],$data[$i][3],"[50%]",10);
				if( count($data[$i])>4 )
					$bar->title->SetFont($data[$i][4],$data[$i][5],$data[$i][6]);
				$bar->SetPattern(BAND_RDIAG,"yellow");
				$bar->SetFillColor("gray");
				$bar->progress->Set(0.5);
				$bar->progress->SetPattern(GANTT_SOLID,"darkgreen");
				$bar->title->SetCSIMTarget(array('#1'.$i,'#2'.$i,'#3'.$i,'#4'.$i,'#5'.$i),array('11'.$i,'22'.$i,'33'.$i));
				$graph->Add($bar);
			}
			$graph->Stroke('monGrapique6.png');
			?>
			<img src="monGrapique6.png" />
		</div>
Là cela ne marche plus.