...

View Full Version : table > caption and firefox



gwendaal
09-27-2004, 09:45 AM
do you know why the render of this code is perfect with IE6 and OPera 7.5 and not with firefox 0.92 ... the caption is totally on the left



<?xml version="1.0" encoding="iso-8859-1"?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr">
<head>
<meta http-equiv="content-type" content="application/xhtml+xml; charset=iso-8859-1" />
<title> Table elements </title>
<style type="text/css">
table {
border:3px solid #6495ed;
border-collapse:collapse;
width:90%;
margin:auto;
}
caption {
font-family:sans-serif;
caption-side:top;
background-color:#2F1F0C;
border:3px solid #6495ed;
color:#FFFFFF;
font-family: Arial, Helvetica, sans-serif;
font-size:16px;
text-align:center;
height:auto;
padding:0.5em;
}
thead, tfoot {
background-color:#D0E3FA;
border:1px solid #6495ed;
}
tbody {
background-color:#FFFFFF;
border:1px solid #6495ed;
}
tr {
background-color:#FFFFFF;
color:#2F1F0C;
}
th {
font-family:monospace;
border:1px dotted #6495ed;
padding:0.5em;
background-color:#EFF6FF;
width:25%;
empty-cells:show;
}
td {
font-family:sans-serif;
font-size:80%;
border:1px solid #6495ed;
color:#2424bb;
padding:0.5em;
text-align:left;
empty-cells:show;
}
</style>
</head>
<body>
<form id="MainForm" method="post" action="">
<table summary="liste de quelques articles publiés
sur OpenWeb regroupés par auteurs et niveaux">
<caption>
Présentation de quelques articles publiés sur OpenWeb
</caption>
<thead>
<tr>
<th></th>
<th>Débutants</th>
<th>Experts</th>
<th>Gourous</th>
</tr>
</thead>
<tfoot>
<tr>
<th></th>
<th>Débutants</th>
<th>Experts</th>
<th>Gourous</th>
</tr>
</tfoot>
<tbody>
<tr>
<th rowspan="2">Tristan Nitot</th>
<td colspan="2">Introduction à l'accessibilité</td>
<td></td>
</tr>
<tr>
<td colspan="3">Interview de Chantal Laplanche, Responsable
Accessibilité Web au Ministère de la Culture</td>
</tr>
</tbody>
<tbody>
<tr>
<th rowspan="2">Laurent Denis</th>
<td>Un exemple de feuille de style
d'impression</td>
<td></td>
<td></td>
</tr>
<tr>
<td></td>
<td colspan="2">Commenter le document de travail
W3C XHTML 2</td>
</tr>
</tbody>
</table>

</form>
</body>
</html>



thank you

coothead
09-27-2004, 10:46 AM
Hi there gwendaal,

try adding...
margin:auto;...to the caption rules.

coothead

gwendaal
09-27-2004, 11:03 AM
wahooou ! :-)

it works ! I did'nt know one could add a margin to a caption

thank you coothead



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum