problème de tableau.

vince
Invité n'ayant pas de compte PHPfrance

03 mars 2005, 16:34

Bonjour, j'ai un petit problème de tableau avec ma page web.

Pour que vous compreniez bien:

ma page contient une <table> globale qui à la taille 750 en largeur et centrée pour permettre l'affichage en resolution 800*600.

Cette balise <table> en contient 5 autre.

Une en haut pour l'entete et 4 en dessous de cette entete. Aux exteme gauche et droite, c'est le tableau qui contient une image d'arriere plan qui forme les bords de mon interface. Et les deux dernières sont le menu et le contenu. Le contenu est un include php que j'apelle par l'url.

Mon problème est le suivant.

lorsque l'include est long tel une page de news, les tableau qui contienne les bords de l'interface (extreme gauche et droite) ne s'étendent pas jusqu'en bas. Donc mon interface n'est pas complete.

J'espere que vous comprenez, c'est pas tres facile a expliquer. Quelqu'un sait il pourquoi ?

Merci d'avance.

Avatar du membre
ViPHP
ViPHP | 3008 Messages

03 mars 2005, 17:20

Le code de ton tableau sera le bienvenu pour qu'on détecte plus vite l'erreur :idea:

Invité
Invité n'ayant pas de compte PHPfrance

03 mars 2005, 17:39

Code : Tout sélectionner

<body background="images/fond.jpg"> <div align="center"> <table width="690" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="100" rowspan="5" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="images/left.jpg"> <tr> <td width="100" height="191">&nbsp;</td> </tr> </table></td> <td width="468" height="16" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="images/up.jpg"> <tr> <td width="468" height="16"></td> </tr> </table></td> <td width="122" rowspan="5" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="images/right.jpg"> <tr> <td width="122" height="191">&nbsp;</td> </tr> </table></td> </tr> <tr> <td height="92" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="images/logo.jpg"> <tr> <td width="468" height="92">&nbsp;</td> </tr> </table></td> </tr> <tr> <td height="54" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="images/down.jpg"> <tr> <td width="468" height="54">&nbsp;</td> </tr> </table></td> </tr> <tr> <td height="16" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="images/menu_bkg.jpg"> <tr> <td width="468" height="16"></td> </tr> </table></td> </tr> <tr> <td height="13" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="images/downer.jpg"> <tr> <td width="468" height="13"></td> </tr> </table></td> </tr> </table> <table width="690" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="45" rowspan="2" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="images/left_scroll.jpg"> <tr> <td width="45" height="106">&nbsp;</td> </tr> </table></td> <td width="120" height="69" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td height="32" colspan="2" valign="top" background="images/cat_flower.jpg">&nbsp;</td> <td width="69" valign="top" background="images/cat_bkg.jpg">&nbsp;</td> <td width="11" valign="top" background="images/cat_end.jpg">&nbsp;</td> </tr> <tr> <td width="14" height="5"></td> <td width="26"></td> <td></td> <td></td> </tr> <tr> <td height="19"></td> <td colspan="2" valign="top"><p>&nbsp;</p> </td> <td></td> </tr> <tr> <td height="13"></td> <td></td> <td></td> <td></td> </tr> </table></td> <td width="30" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td width="30" height="69">&nbsp;</td> </tr> </table></td> <td width="450" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td height="32" colspan="2" valign="top" background="images/cat_flower.jpg">&nbsp;</td> <td width="399" valign="top" background="images/cat_bkg.jpg">&nbsp;</td> <td width="11" valign="top" background="images/cat_end.jpg">&nbsp;</td> </tr> <tr> <td width="14" height="5"></td> <td width="26"></td> <td></td> <td></td> </tr> <tr> <td height="19"></td> <td colspan="2" valign="top"><p>&nbsp;</p> </td> <td></td> </tr> <tr> <td height="13"></td> <td></td> <td></td> <td></td> </tr> </table></td> <td width="45" rowspan="2" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0" background="images/right_scroll.jpg"> <tr> <td width="45" height="106">&nbsp;</td> </tr> </table></td> </tr> <tr> <td height="37"></td> <td></td> <td></td> </tr> </table> </div> </body>
Le voila, c'est mon interface sans aucun texte, juste les tableaux avec les images de fonds.

Avatar du membre
ViPHP
ViPHP | 3008 Messages

03 mars 2005, 17:56

wow !!! tu en as des tableaux dis moi dur dur de s'y retrouver...Tu utilises dreamweaver pour faire le code ? SI tu peux utiliser un éditeur de texte ça serait génial et ton code sera nickel.

Je crois voir pourquoi ça ne s'étend pas. En fait quand tu mets un tableau dans un tableau, celui qui est à l'intérieur ne s'étend pas à 100% et ne suit donc pas le tableau externe. Il ne suit que la longueur du contenu qu'il contient.

Je ne sais pas si c'est vraiment ça que tu demandes parce que j'ai un peu de mal à comprendre. Si ce n'est pas ça, n'hésites pas :)

Tu as une adresse où on peut voir la page en ligne ?

vince
Invité n'ayant pas de compte PHPfrance

03 mars 2005, 18:04

oui j'utilise dreamweaver.

je comprend ce que tu veux dire et ca doit etre ca le probleme.

Mais que me conseille tu ?

Faire un seul <table> et mon interface ne serai contenue que dans des <td> ?

Je vais tenter ca pour voir.

Eléphant du PHP | 334 Messages

03 mars 2005, 18:18


Avatar du membre
ViPHP
ViPHP | 3008 Messages

04 mars 2005, 10:04

Excellent ton lien jerem' :D

Vince essaies déjà de supprimer la maximum de tableaux. La construction que tu veux faire n'en nécessite pas autant.

Si tu veux que ça suive aux côtés, tu dois obligatoirement supprimer les sous-tableaux que tu as mis et mettre ton contenu directement dans les <td> en question.

A++