I have a web page that has a table and inside one of the td is span that uses a smaller font, float right to place it to the far right, and a negative margin-top, so it is aligned with larger text in the td.
With Firefox 3.0 it works fine, but I just updated to Firefox 3.5 and the margin is moving the text up too far.
I have another page, where there are two span entries, again the second with a smaller font and negative margin and shows the same issue.
On a third page, with a h3 followed by a span, a smaller font and negative margin, it works fine in Firefox 3.5.
I installed Safari today and it acts the same as Firefox 3.5. I don't have an issue with IE, as I have conditional CSS to handle the different IE versions (IE 7 uses a negative margin, but IE 8 uses a small positive margin).
Questions (finally :^):
Is anyone aware of changes in rendering for span and negative margins for Firefox 3.5?
How else could I write the HTML or CSS, to obtain the same result w/o browser specific hacks?
For the second case, I changed it from two spans, to an h3 and span, like the third case. The first case really is tabular data, so I'm using the table. Here's a fragment of the issue:
<div id="content">
<table id="events2" cellspacing="0">
<tr class="month">
<td>August 2009<span class="gotop">(go to top)</span>
</td></tr>
<tr>
<td>
A table row</td>
</tr>
</table>
The pertinent (I hope) CSS is:
div#content {
margin: 0;
padding: 0
width:100%;
background: white;
color: black;
font-size: 80%;
}
#events2 td {
padding: 4px;
border-bottom: 2px solid #BBB;
}
#events2 tr.month td {
padding: 0.125em 0;
font-size: 1.2em;
text-align: center;
border-top: 3px solid black;
border-bottom: 2px solid #BBB;
}
#events2 tr.month td .gotop {
float: right;
font-size: 0.6em;
margin-top: -1.4em;
padding-bottom: 0.3em;
}
Thanks in advance! PCM