je cherche à transformer mes tableaux en format CSS mais j'avoue être nul dans ce domaine.
Quelqu'un pourrait-il m'aider à faire la modification.
Voici le code utilisé: Il y a deux tableaux l'un dans l'autre (vous pouvez voir le résultat sur ce site http://www.myvideos.fr) et voir ce que ça donne en affichant le code source.
Merci d'avance de votre aide...
<table width="1150" align="center">
<tr>
<td valign="top" class="td_index"><h1 align="center">Les dernières vidéos mises en ligne.</h1>
<br />
<?php
$reponse = mysqli_query($bdd, "SELECT membres.id, pseudo, avatar FROM video, membres WHERE video.id_membre=membres.id and valide=1 ORDER BY video.id DESC LIMIT 0,13")or die(mysqli_error($bdd));
$sql = mysqli_query($bdd, "SELECT * FROM video WHERE valide = 1 ORDER BY id DESC LIMIT 0,13")or die(mysqli_error($bdd));
$row = mysqli_query($bdd, 'sql');
while($row = mysqli_fetch_assoc($sql))
{
$vidid=$row['id'];
$donnees = mysqli_fetch_assoc($reponse);
$result = mysqli_query($bdd, "SELECT COUNT(page_id) as nb FROM comments WHERE page_id=".$vidid."")or die(mysqli_error($bdd));
$com = mysqli_fetch_assoc($result);
?>
<table width="792" align="center">
<tr>
<td width="165"><a href="video-<?php echo $vidid; ?>.html" class="result" rel="nofollow"><img src="<?php echo $row['thumb']; ?>" alt="" width="150" border="0" align="absmiddle" class="arrondie" /></a></td>
<td width="391"><div align="absmiddle">Vidéo vue <?php echo $row['vu']; ?> fois
<br />
<?php echo'<br />';if($com['nb']=="0") echo 'Pas encore de commentaire sur cette vidéo<br />
<a href="video-'.$vidid.'.html" class="result" rel="nofollow">Commenter cette vidéo</a>';
elseif($com['nb']=="1") echo '1 commentaire sur cette vidéo<br /><a href="video-'.$vidid.'.html" class="result" rel="nofollow">Ajouter un commentaire</>'; elseif ($com['nb']>="2") echo''.$com['nb'].' commentaires sur cette vidéo<br /><a href="video-'.$vidid.'.html" class="result" rel="nofollow">Ajouter un commentaire</a>'; ?> </td>
<td width="220"><?php
if ($donnees['avatar'] =="")
{
?>
<img src="images/point interrogation.jpg" width="35px" align="absmiddle" alt=""/>
<?php } else {
?>
<img src="avatar/<?php echo $donnees['avatar'];?>" width="35px" align="absmiddle" alt=""/>
<?php } if ($_SESSION['id']!=$row['id_membre']) {?> Postée par : <a href="membre-<?php echo $row['id_membre'];?>.html"><?php echo $donnees['pseudo']; ?></a><?php } else { echo ' Postée par : '.$donnees['pseudo']; } ?><br />
<br /><?php echo rating_bar(''.$row['id'].'',5); ?></td>
</tr>
<tr>
<td colspan="3" class="tr">
<br />
<a href="video-<?php echo $vidid; ?>.html" class="result" title="<?php echo $row['title']; ?>" rel="nofollow"><?php echo $row['title']; ?></a><br />
<?php if($row['description']=="") echo'La description n\'est pas renseignée par l\'auteur de la vidéo...'; else echo stripslashes($row['description']); ?>
<br /></td>
</tr>
<tr>
<td colspan="3"><hr /></td>
</tr>
</table>
<?php
}
?>
</div></td><td width="264" valign="top"><?php
include('menu.php'); ?> </td></tr></table>