par
simchichi » 01 sept. 2006, 19:27
Attention débutant

(dsl si c'est pas dans la bonne zone adéquate pour se sujet)
j'ai voulu mettre en place une petit page internet récapitulant l'ensemble de mes photos. Lorsque qu'on clique sur une lettre, elle renvoi une page html incorporé dans la page php... j'ai utilisé la balise include ça marche pas. pouvez-vous m'aider. merci dévance
Code : Tout sélectionner
<html>
<head>
<title>.::[ Mes Photos ]::.</title>
<SCRIPT LANGUAGE=JavaScript>
function ejs_img_fx(img){
if(img && img.filters && img.filters[0]){
img.filters[0].apply();
img.filters[0].play();
}
}
</SCRIPT>
</head>
<body>
<body bgcolor=#4BB7E2>
<img src="logo.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)">
<div id="menu">
<ul>
<a href="index.php?pg=09"><img src="09.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=j"><img src="j.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=k"><img src="k.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=l"><img src="l.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=m"><img src="m.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=n"><img src="n.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=o"><img src="o.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=p"><img src="p.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=q"><img src="q.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=r"><img src="r.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=s"><img src="s.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=t"><img src="t.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=u"><img src="u.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=v"><img src="v.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=w"><img src="w.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=x"><img src="x.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=y"><img src="y.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=z"><img src="z.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
</ul>
</div>
<div id="contenu">
<?php
$autorise = array( '09' => '09.html',
'j' => 'j.html',
'k' => 'k.html',
'l' => 'l.html',
'm' => 'm.html',
'n' => 'n.html',
'o' => 'o.html',
'p' => 'p.html',
'q' => 'q.html',
'r' => 'r.html',
's' => 's.html',
't' => 't.html',
'u' => 'u.html',
'v' => 'v.html',
'w' => 'w.html',
'x' => 'x.html',
'y' => 'y.html',
'z' => 'z.html'); // On stocke l'ensemble des pages valides dans le tableau associatif $autorise[]
if ( (isset($_GET['pg'])) && (isset($autorise[$_GET['pg']])) ) { // Si $_GET['pg'] existe et si $_GET['pg'] correspond à une des données du tableau
include($autorise[$_GET['pg']]); // Alors on inclut le fichier correspondant
} else { // Si $_GET['pg'] n'existe pas ou $_GET['pg'] n'est pas autorisé
include('accueil.html'); // On inclut la page par défaut accueil.php
}
?>
</div>
</body>
</html>
voici "l'erreur" renvoyée:

Attention débutant :) (dsl si c'est pas dans la bonne zone adéquate pour se sujet)
j'ai voulu mettre en place une petit page internet récapitulant l'ensemble de mes photos. Lorsque qu'on clique sur une lettre, elle renvoi une page html incorporé dans la page php... j'ai utilisé la balise include ça marche pas. pouvez-vous m'aider. merci dévance
[code]<html>
<head>
<title>.::[ Mes Photos ]::.</title>
<SCRIPT LANGUAGE=JavaScript>
function ejs_img_fx(img){
if(img && img.filters && img.filters[0]){
img.filters[0].apply();
img.filters[0].play();
}
}
</SCRIPT>
</head>
<body>
<body bgcolor=#4BB7E2>
<img src="logo.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)">
<div id="menu">
<ul>
<a href="index.php?pg=09"><img src="09.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=j"><img src="j.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=k"><img src="k.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=l"><img src="l.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=m"><img src="m.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=n"><img src="n.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=o"><img src="o.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=p"><img src="p.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=q"><img src="q.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=r"><img src="r.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=s"><img src="s.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=t"><img src="t.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=u"><img src="u.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=v"><img src="v.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=w"><img src="w.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=x"><img src="x.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=y"><img src="y.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
<a href="index.php?pg=z"><img src="z.gif" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" onLoad="ejs_img_fx(this)" onMouseOver="ejs_img_fx(this)" border=no></a>
</ul>
</div>
<div id="contenu">
<?php
$autorise = array( '09' => '09.html',
'j' => 'j.html',
'k' => 'k.html',
'l' => 'l.html',
'm' => 'm.html',
'n' => 'n.html',
'o' => 'o.html',
'p' => 'p.html',
'q' => 'q.html',
'r' => 'r.html',
's' => 's.html',
't' => 't.html',
'u' => 'u.html',
'v' => 'v.html',
'w' => 'w.html',
'x' => 'x.html',
'y' => 'y.html',
'z' => 'z.html'); // On stocke l'ensemble des pages valides dans le tableau associatif $autorise[]
if ( (isset($_GET['pg'])) && (isset($autorise[$_GET['pg']])) ) { // Si $_GET['pg'] existe et si $_GET['pg'] correspond à une des données du tableau
include($autorise[$_GET['pg']]); // Alors on inclut le fichier correspondant
} else { // Si $_GET['pg'] n'existe pas ou $_GET['pg'] n'est pas autorisé
include('accueil.html'); // On inclut la page par défaut accueil.php
}
?>
</div>
</body>
</html>
[/code]
voici "l'erreur" renvoyée:
[url=http://www.mezimages.com/agrandir.php?fi=/09/1090073php.GIF][img]http://up.mezimages.com/up/09/miniature/mini_1090073php.GIF[/img][/url]