|
La Communauté Webmaster 
| Pages: [1] |
 |
|
|
|
Auteur |
Sujet: probleme récupération variable et insertion (Lu 849 fois) |
|
 |
probleme récupération variable et insertion
« sur: le 16-07-2006 a 18:14:58 » |
|
sparh
Membre récent

Hors-Ligne
Sexe: 
Messages: 11

Je suis un lama!
|
Salut à tous, je me tente à la création de page dynamique, tout allé bien mais là je bloque sur un pti problème et j'arrive pas à le résoudre Voilà ma page qui récupère la valeur envoyé pour permettre de jouer. J'arrive à récupérer les variables pour le nom du jeux et le texte mais ensuite il faut que je récupère la variable: adresse qui est l'adresse du jeu flash. Impossible de récupérer le champ adresse. (<? echo $row['adresse'] ?>) et surtout de l'insérer au bon endroit pour que le jeu se lance! Si quelqu'un avait une idée pour me débloquer, merci d'avance 
<body bgcolor="#14285f"> <table width="100%" border="1"> <tr> <td height="120" colspan="3" align="center" bgcolor="#000000"><img src="../Image/logo.gif" alt="Sparh Prods" width="500" height="78" longdesc="Image/logo.gif" /></td> </tr> <tr> <td height="1" colspan="3" align="center" bgcolor="#000000"><table width="800"> <tr> <td> </td> </tr> </table></td> </tr> <tr> <td width="156" height="508" align="center" valign="top"><table width="157"> <tr> <td height="25" align="center" id="navigation"><a href="#">Accueil</a></td> </tr> <tr> <td height="25" align="center" id="navigation"><a href="#">Zone membre</a> </td> </tr> <tr> <td height="25" align="center" id="navigation"><a href="#">Actualités</a></td> </tr> <tr> <td height="25" align="center" id="navigation"><a href="#">Vidéos</a></td> </tr> <tr> <td height="25" align="center" id="navigation"><a href="#">Musique</a></td> </tr> <tr> <td height="25" align="center" id="navigation"><a href="#">Jeux</a></td> </tr> <tr> <td height="25" align="center" id="navigation"><a href="#">Yetisports</a></td> </tr> <tr> <td height="25" align="center" id="navigation"><a href="#">Les blagues</a> </td> </tr> <tr> <td height="25" align="center" id="navigation">Les haikus </td> </tr> <tr> <td height="25" align="center" id="navigation">Les textes </td> </tr> <tr> <td height="25" align="center" id="navigation"> </td> </tr> <tr> <td height="25" align="center" id="navigation"> </td> </tr> <tr> <td height="25" align="center" id="navigation"> </td> </tr> <tr> <td height="25" align="center" id="navigation"> </td> </tr> </table></td> <td width="540"><? $jeu=$_GET['jeux']; include"config.php"; @mysql_connect($serveur, $login, $password)or die ("impossible de se connecter"); mysql_select_db($base)or die ("impossible de se connecter a la base"); $result=mysql_query("SELECT jeux,image1,image2,texte,categorie1,categorie2,vote,adresse FROM Jeux WHERE jeux='$jeu' ");
while($row=mysql_fetch_array($result)) { print("<h1>$row[jeux]</h1> $row[texte]<br><br>"); } ?> <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="304" height="200" title="Yetisport"> <param name="movie" value="<? echo $row['adresse'] ?>" /> <param name="quality" value="high" /> <embed src="<? echo $row['adresse'] ?>" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="304" height="200"></embed> </object></td> <td width="215"> </td> </tr> <tr> <td height="108"> </td> <td> </td> <td> </td> </tr> </table> </body> |
| |
|
|
|
|
|
|
 |
Re:probleme récupération variable et insertion
« Répondre #1 sur: le 21-07-2006 a 21:43:39 » |
|
sparh
Membre récent

Hors-Ligne
Sexe: 
Messages: 11

Je suis un lama!
|
bon j'met la solution au cas ou  voilà les changement et ca marche
while($row=mysql_fetch_array($result)) { print("<h1>$row[jeux]</h1> $row[texte]<br><br>") ?> <center><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="304" height="200" title="<?php echo $row['jeux'] ?>"> <param name="movie" value="<?php echo $row['adresse'] ?>" /> <param name="quality" value="high" /> <embed src="<?php echo $row['adresse'] ?>" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="304" height="200"></embed> </object><p> <a href="<?php echo $row['adresse'] ?>" onclick="popUp(this.href,'fixed',400,608);return false;" title="<?php echo $row['jeux'] ?>">Cliquez jouer à <?php echo $row['jeux'] ?> en plus grand</a></p> <table width="328" border="1"> <tr> <td width="66" ><div align="center"><strong>Score</strong></div></td> <td width="66" ><div align="center"><strong>Nom</strong></div></td> <td width="180" ><div align="center"><strong>Commentaire</strong></div></td> </tr><?php mysql_connect($serveur, $login, $password)or die ("impossible de se connecter"); mysql_select_db($base)or die ("impossible de se connecter a la base"); $requete = $sql = 'SELECT `Record`.*' . ' FROM Record' . ' WHERE (`Record`.`jeu` ="$row[jeux]")' . ' ORDER BY `Record`.`score` DESC LIMIT 0, 8 '; $resultat=mysql_query($requete,$id_connexion);
while ($tableau=mysql_fetch_array($resultat,MYSQL_ASSOC)) { echo '</td><td><center>',$tableau['Score'],'</center></td> <td><center>',$tableau['Nom'],'</center></td><td><center>',$tableau['Com'],'</center></td></tr>'; } mysql_close(); ?> </table> <form name"record" action="../record.php?Jeu=<?php echo $row['jeux'] ?>" target="popUp" method="get"/> <input name="submit" type="submit" value="Enregistrez votre record" onclick="popUp(this.href,'fixed',250,250);return false;"/> </form> <br /> </center> <!-- InstanceEndEditable --></td> <td width="24"> </td> <td width="155" align="right" valign="top"><!-- InstanceBeginEditable name="titredroit" --> <center> Sparh Prods en association avec la Manouch team vous proposent le Haiku du jour: </center> <!-- InstanceEndEditable --><!-- InstanceBeginEditable name="rightbox" --> <div id="hai"> <center> lE HIKU DU JOUR<br /> celui qui pete tout<br /> en revoir et a bientot midi les zou et tire re pe ds </center> <a href="http://sparh.free.fr/Haiku/Haikus_du_jour.php" onclick="popUp(this.href,'fixed',400,420);return false;" title="Enregistrez votre haiku">Ajoutez le votre</a></div> <br /> <!-- InstanceEndEditable --></td> <td width="108"> </td> </tr> <tr> <td height="108" colspan="2"> </td> <td colspan="3" align="center"><!-- InstanceBeginEditable name="bas" --> <p> <? include("../visite.php"); print" <div align=center><font face=Verdana, Arial, Helvetica, sans-serif size=1>Nombre de visiteurs:<b><font color=#FF0000>$compteur</font></b> depuis le <br />15 Octobre 2005</font> </div>"; print" <div align=center><font face=Verdana, Arial, Helvetica, sans-serif size=1>Nombre de visiteurs aujourd'hui: <b><font color=#FF0000>$compteur_j</font></b></font> </div>"; print" <div align=center><font face=Verdana, Arial, Helvetica, sans-serif size=1>Nombre de connectés:<b><font color=#FF0000>$compteur_c</font></b></font> </div>"; print" <div align=center><font face=Verdana, Arial, Helvetica, sans-serif size=1><b><font color=#FF0000>$total</font></b> connecté sur le chat.</font> </div>"; ?> <br /> <a href="mailto:gaspardtoussaint@hotmail.com" title="Contactez le webmaster" class="style1">Gaspard Toussaint</a> </p> <p></p> <!-- InstanceEndEditable --></td> <td align="center"> </td> <td> </td> </tr> </table> </body> <!-- InstanceEnd --></html><?php } ?>
|
| |
|
|
|
|
| Pages:
[1] |
|
|
|
| |
|
|