<img src="url_dossier/<?php echo $nom;?>.jpg" width="" height="" alt="" /><?
$NbrCol = 4;
// requete
$table = 'etudiant';
$condition = ' WHERE DONNEE LIKE \'b%\' ORDER BY DONNEE ASC';
$query = 'SELECT * FROM '.$table;
$result = mysql_query($query);
// -------------------------------------------------------
$NbreData = mysql_num_rows($result);
// -------------------------------------------------------
// affichage
$NbrLigne = 0;
if ($NbreData != 0) {
$j = 1;
echo '<table border="1">';
while ($val = mysql_fetch_array($result)) {
if ($j%$NbrCol == 1) {
$NbrLigne++;
echo "<tr>";
$fintr = 0;
}
echo '<td>';
// ------------------------------------------
// AFFICHAGE des DONNEES de la fiche
echo $val['id'];
echo <img src="../Image/<?php echo $val'[id'];?>.jpg" width="35" height="36" alt="" />
echo '<br>';
echo '<i>'.$val['nom'].'</i>';
// ------------------------------------------
echo '</td>';
if ($j%$NbrCol == 0) {
echo "</tr>";
$fintr = 1;
}
$j++;
}
if ($fintr!=1) { echo '</tr>'; }
echo '</table>';
} else {
echo 'pas de données à afficher';
}
?>
echo <img src Il manque quelque chose à ce niveau<?
$NbrCol = 4;
// requete
$table = 'etudiant';
$condition = ' WHERE DONNEE LIKE \'b%\' ORDER BY DONNEE ASC';
$query = 'SELECT * FROM '.$table;
$result = mysql_query($query);
// -------------------------------------------------------
$NbreData = mysql_num_rows($result);
// -------------------------------------------------------
// affichage
$NbrLigne = 0;
if ($NbreData != 0) {
$j = 1;
echo '<table border="1">';
while ($val = mysql_fetch_array($result)) {
if ($j%$NbrCol == 1) {
$NbrLigne++;
echo "<tr>";
$fintr = 0;
}
echo '<td>';
// ------------------------------------------
// AFFICHAGE des DONNEES de la fiche
echo $val['id'];
echo '<img src="../Image/'.$val'[id'].'.jpg" width="35" height="36" alt="" />';
echo '<br>';
echo '<i>'.$val['nom'].'</i>';
// ------------------------------------------
echo '</td>';
if ($j%$NbrCol == 0) {
echo "</tr>";
$fintr = 1;
}
$j++;
}
if ($fintr!=1) { echo '</tr>'; }
echo '</table>';
} else {
echo 'pas de données à afficher';
}
?>
Il faudrais faire comme ca:si je fais ça qu'est ce qui ne va pasecho '<img src="../Image/.$val['id'].jpg width="35" height="36" alt="" /> ';
echo '<img src="../Image/.$val[id].jpg width="35" height="36" alt="" /> ';
echo '<img src="../Image/$val[id].jpg width="35" height="36" alt="" /> ';
echo '<img src="../Image/'.$val['id'].'.jpg" width="35" height="36" alt="" />';
c'est mieux invité et sasuukeOui c est se que j ai mis juste au dessusRegarde comment faire une concaténation.c'est mieux invité et sasuukeecho '<img src="../Image/'.$val['id'].'.jpg" width="35" height="36" alt="" />';
Mmmhh pas vraiment non, ton code ne fonctionnera pas.Oui c est se que j ai mis juste au dessus