Michel,
My default stylesheet has td text-align:left because that's the 90% case. If I need centered or right aligned I override the setting for the specific element typically with a right-align or center-align class (or element style if you have to).
Not specifying text-align: left causes a lot of problems as the setting otherwise is 'inherit'. If the table's outer element has text-align: center all columns in the table will center which is surely not what you want.
In my standard CSS file I have:
td
{
text-align: left;
vertical-align: top;
padding: 4px;
}
table.grid>tbody>tr>td
{
border: solid 1px lightgrey;
}
th
{
font-weight: bold;
text-align: center;
}
Hope that helps,
+++ Rick ---
>In HTML5, depending on the context, some TD cell alignments might end up to be aligned centered even if you did not specify to. This is just how HTML5 renders its stuff.
>
>So, I thought I would put this in my stylesheet:
>
>
>TD
>{
> Text-Align: Left;
>}
>
>
>While this resolves some issues, it causes some more as this has priority over the attribute ALIGN=CENTER, for example.
>
>I would like to know how you handle it. Do you prefer to have it declared at the stylesheet level and fix at every locations or not having it at the stylesheet level but to fix those locations where the TD cell appears centered?