Afficher des photos dans un tableau
beavogu
Messages postés
1
Statut
Membre
-
Yuh12 Messages postés 184 Date d'inscription Statut Membre Dernière intervention -
Yuh12 Messages postés 184 Date d'inscription Statut Membre Dernière intervention -
Bonjour, j'ai écrit un code pour ajouter les noms des élèves leurs adresses et leurs photos dans une bdb avec php ça fonctionne bien. je parviens à afficher les noms et les adresses dans le tableau, mais les photos ne affiche pas
voici le code:
<?php
require_once("connection.php");
$req="select * from ELEVE";
$rs=$conn->prepare($req) ;
$rs->execute();
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
</head>
<body>
<table border="1" width="70%">
<tr>
<th>CODE</th><th>NOM</th><th>EMAIL</th><th>POTHOS</th>
</tr>
<?php while ($EL=$rs->fetch()) {?>
<tr>
<td><?php echo ($EL['CODE']); ?></td>
<td><?php echo ($EL['NOM']); ?></td>
<td><?php echo ($EL['EMAIL']); ?></td>
<td><img src="images/<?php echo ($EL['POTHOS']); ?> "/></td>
</tr>
<?php }
$rs->closeCursor();
?>
</table>
</body>
</html>
Quelqu'un peut-il m'aider!
voici le code:
<?php
require_once("connection.php");
$req="select * from ELEVE";
$rs=$conn->prepare($req) ;
$rs->execute();
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
</head>
<body>
<table border="1" width="70%">
<tr>
<th>CODE</th><th>NOM</th><th>EMAIL</th><th>POTHOS</th>
</tr>
<?php while ($EL=$rs->fetch()) {?>
<tr>
<td><?php echo ($EL['CODE']); ?></td>
<td><?php echo ($EL['NOM']); ?></td>
<td><?php echo ($EL['EMAIL']); ?></td>
<td><img src="images/<?php echo ($EL['POTHOS']); ?> "/></td>
</tr>
<?php }
$rs->closeCursor();
?>
</table>
</body>
</html>
Quelqu'un peut-il m'aider!
A voir également:
- Afficher des photos dans un tableau
- Partager des photos - Guide
- Tableau word - Guide
- Trier un tableau excel - Guide
- Tableau ascii - Guide
- Toutes mes photos - Guide