La Communauté Webmaster  forum rss


  Forum-webmaster
  Technique - programmation
  PHP / MySQL
(Modérateurs: Shain, Jey, erwinol, Lilian, lauryv, ToToMaStEr)
  probleme récupération variable et insertion
« Précédent Suivant »
Pages: [1] Descendre
Répondre    Aviser des réponses    Envoyer le sujet    Imprimer
  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: Male
Messages: 11



Je suis un lama!

Voir le Profil    WWW
Répondre avec citation

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
Code:
<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>&nbsp;</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&eacute;s</a></td>
      </tr>
      <tr>
        <td height="25" align="center" id="navigation"><a href="#">Vid&eacute;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">&nbsp;</td>
      </tr>
      <tr>
        <td height="25" align="center" id="navigation">&nbsp;</td>
      </tr>
      <tr>
        <td height="25" align="center" id="navigation">&nbsp;</td>
      </tr>
      <tr>
        <td height="25" align="center" id="navigation">&nbsp;</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">&nbsp;</td>
  </tr>
  <tr>
    <td height="108">&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
</table>
</body>

Rapporter au modérateur  

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: Male
Messages: 11



Je suis un lama!

Voir le Profil    WWW
Répondre avec citation

bon j'met la solution au cas ou
voilà les changement et ca marche
Code:
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  &agrave; <?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">&nbsp;</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">&nbsp;</td>
  </tr>
  <tr>
    <td height="108" colspan="2">&nbsp;</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&eacute;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">&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
</table>
</body>
<!-- InstanceEnd --></html><?php } ?>

Rapporter au modérateur  
Répondre    Aviser des réponses    Envoyer le sujet    Imprimer
Pages: [1] Monter
« Précédent Suivant »
Sauter à: 

Votre statut : Invité
Vous devez être membre pour participer.
 
 
Let’s Encrypt : le certificat SSL gratuit
Tester votre site internet sur différents navigateurs
[WordPress] Des problèmes avec l’administration ?
Rappel : Mettez à jour vos CMS et vos sites E-commerce
Le .fr fête ses 25 années d’existence !
Mesurer votre audience en temps réel avec BubbleStat
Porter réclamation contre Google Panda ?
Zlio n’est plus …
 
 
 
 
 

Copyright (c) Devclic 2002 - 2026 - Tous droits réservés

creation site internet strasbourg