La boucle while ne retourne rien
mari1995@
Messages postés
2
Date d'inscription
Statut
Membre
Dernière intervention
-
jordane45 Messages postés 30426 Date d'inscription Statut Modérateur Dernière intervention -
jordane45 Messages postés 30426 Date d'inscription Statut Modérateur Dernière intervention -
bonjour, svp j'ai un probleme dans ma boucle while, apres l'execution aucun msg d'erreur d'erreur n'est affiché ms la boucle while ne retourne rien voilà mon code
<body id="page-top" class="index">
<section id="portfolio" class="bg-light-gray">
<div class="container-fluid">
<div class="col-lg-12 text-center">
<?php
require'connexion.php';
$conn=connex();
$login=isset($_POST['NomPrenom'])?$_POST['NomPrenom']:'';
$password=isset($_POST['password'])?$_POST['password']:'';
$var="SELECT * FROM table2 WHERE NomPrenom='$login' AND CIN='$password'";
$result = $conn->query($var) or die (print_r($conn->errorInfo()));
?>
<div class="row">
<div class="col-md-12">
<h3 class="text-center">Bienvenue dans votre espace</h3> <br>
</div>
<div id="no-more-tables">
<table class="col-md-12 table-bordered table-striped table-condensed cf">
<thead class="cf">
<tr>
<th class="numeric">Id</th>
<th class="numeric">Nom et Prenom</th>
<th class="numeric">CIN</th>
<th class="numeric">Echelle</th>
<th class="numeric">Votre Demande</th>
<th class="numeric">validation</th>
</tr>
</thead>
<?php
while($row=$result->fetch(PDO::FETCH_ASSOC))
{
?>
<tr>
<td><?php echo $row['Id']; ?></td>
<td><?php echo $row['NomPrenom']; ?></td>
<td><?php echo $row['CIN']; ?></td>
<td><?php echo $row['Echelle']; ?></td>
<td><?php echo $row['demande']; ?></td>
<td><?php echo $row['validation']; ?></td>
</tr>
<?php
}
?>
</table>
</div>
</div>
</div>
</div>
</section>
</body>
</html>
EDIT : Ajout des balises de code (la coloration syntaxique).
Explications disponibles ici :ICIMerci d'y penser dans tes prochains messages.Jordane45 |