Précédent   Forum des professionnels en informatique > PHP > PHP & SGBD > PHP & MySQL
PHP & MySQL Forum d'entraide sur les fonctions MySQL avec PHP. Avant de poster -> FAQ MySQL, Cours MySQL et Sources MySQL. Pour les questions concernant le moteur MySQL plutôt que les fonctions PHP, merci d'utiliser le forum MySQL.
Partagez cette discussion sur d'autres réseaux sociaux : Viadeo Twitter Google Facebook Digg Delicious MySpace Yahoo
Réponse Proposer ce sujet en actualité
 
Outils de la discussion
Publicité
'
Vieux 29/12/2010, 17h08   #1
Membre éprouvé
 
Avatar de _shuriken_
 
Homme
Consultant telecoms
Inscription : mars 2006
Messages : 426
Détails du profil
Informations personnelles :
Sexe : Homme
Âge : 27

Informations professionnelles :
Activité : Consultant telecoms
Secteur : High Tech - Opérateur de télécommunications

Informations forums :
Inscription : mars 2006
Messages : 426
Points : 410
Points : 410
Par défaut Listing et affichage d'un select

Bonjour,

Quelqu'un peut me dire ce qui ne va pas avec ce code ? Il ne m'affiche rien du tout .
Code :
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
 
<?php	
	while ($data = mysql_fetch_array($req)) {
 
// On affiche les résultats
?>
		<td><?php echo '$data[`CLIENT_ID`].>'; ?></td>
 
		<td><?php echo '$data[`NOM_CLT`].>'; ?></td>
 
		<td><?php echo '$data[`PNOM_CLT`].>'; ?></td>
 
		<td><?php echo '$data[`ADR_CLT`].>'; ?></td>
 
		<td><?php echo '$data[`PROF_CLT`].>'; ?></td>
 
		<td><?php echo '$data[`C_ID`].>'; ?></td>
 
		<td><?php echo '$data[`DATE_CREATION`].>'; ?></td>
 
echo "</TR>"
__________________
"When you can measure what you are speaking about, and express it in numbers, you know something about it; but when you cannot measure it, when you cannot express it in numbers, your knowledge is of a meager and unsatisfactory kind; it may be the beginning of knowledge, but you have scarcely in your thoughts advanced to the state of Science, whatever the matter may be."

Lord Kelvin - 1883.
_shuriken_ est déconnecté   Envoyer un message privé Réponse avec citation 00
Vieux 29/12/2010, 17h49   #2
Membre Expert
 
Avatar de Madfrix
 
Inscription : juin 2007
Messages : 2 278
Détails du profil
Informations personnelles :
Localisation : France, Gironde (Aquitaine)

Informations forums :
Inscription : juin 2007
Messages : 2 278
Points : 2 324
Points : 2 324
Bonjour,

Code php :
1
2
3
4
 
...
<td><?php echo $data['CLIENT_ID'].'>'; ?></td>
...
Madfrix est déconnecté   Envoyer un message privé Réponse avec citation 00
Vieux 29/12/2010, 17h53   #3
Membre actif
 
Tobbi Filteau
Inscription : mai 2010
Messages : 176
Détails du profil
Informations personnelles :
Nom : Tobbi Filteau

Informations forums :
Inscription : mai 2010
Messages : 176
Points : 177
Points : 177
Il y a effectivement quelques petites erreurs dans ta ligne:

Code :
1
2
 
<?php echo '$data[`CLIENT_ID`].>'; ?>
Devrait plutôt ressembler à:

Code :
1
2
 
<?php echo $data['CLIENT_ID'] . '>'; ?>
La même erreur se répète à chaque ligne alors n'oublie pas de faire la correction partout .

Bonne chance

Osu
osuwariboy est déconnecté   Envoyer un message privé Réponse avec citation 00
Vieux 29/12/2010, 18h04   #4
Membre éprouvé
 
Avatar de _shuriken_
 
Homme
Consultant telecoms
Inscription : mars 2006
Messages : 426
Détails du profil
Informations personnelles :
Sexe : Homme
Âge : 27

Informations professionnelles :
Activité : Consultant telecoms
Secteur : High Tech - Opérateur de télécommunications

Informations forums :
Inscription : mars 2006
Messages : 426
Points : 410
Points : 410
ça marche, merci à vous 2 !
__________________
"When you can measure what you are speaking about, and express it in numbers, you know something about it; but when you cannot measure it, when you cannot express it in numbers, your knowledge is of a meager and unsatisfactory kind; it may be the beginning of knowledge, but you have scarcely in your thoughts advanced to the state of Science, whatever the matter may be."

Lord Kelvin - 1883.
_shuriken_ est déconnecté   Envoyer un message privé Réponse avec citation 00
Réponse Proposer ce sujet en actualité Cette discussion est résolue.
Outils de la discussion



Fuseau horaire GMT +2. Il est actuellement 12h24.


 
 
 
 
Partenaires

Hébergement Web