Geologist1724
01-18-2009, 10:06 PM
Hey There all of you great programmers at DD.
I am trying to absolutely position a very short amount of text (2 words) in a cell. I don't want it positioned relative to the document window. So of course everybody says I have to position it absolutely relative to a container. The logical container for my layout is the cell the text is in. I'm sure you already know this doesn't work. After much frustration I finally found DD"s jscheuer1 2007 response indicating that most browsers will not allow a td to have relative position.
Ok so half heartedly I tried putting my cell inside a table and positioning the text relative to the table. That doesn't work either. So what elements can be used as containers?
Here is my CSS:
/* This is my container*/
#table {
position: relative;
}
/* Begin Member Companies*/
#company a:link{
position: absolute;
top: 84px;
left: 4px;
font-size: 12px;
font-weight: bold;
color: #094054;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-style: italic;
}
The rest of my #company declarations are exactly like a:link, except hover has a little text decoration.
And here is my HTML:
<!-- Absolute Relative Positioning-->
<div id="table">
<td width="207" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0">
<!--DWLayoutTable-->
<tr>
<td width="207" height="120" valign="top" background="images/Right_Top.gif">
<div id="company"><a href="http://www.pcpg.org/pcpg_members.html">Member Companies</a></div>
</td>
</tr>
</table>
</td>
</div>
<!--End Absolute Positioning-->
So if tds can't be relatively positioned, what can I use as a container?
Here is the URL for this page. When I open it in either Firefox or IE7 the text "Member Companies" is parsed relative to the document window.
http://www.harrisburgmarathon.com/Z_New/Experiment_ab.asp
I am trying to absolutely position a very short amount of text (2 words) in a cell. I don't want it positioned relative to the document window. So of course everybody says I have to position it absolutely relative to a container. The logical container for my layout is the cell the text is in. I'm sure you already know this doesn't work. After much frustration I finally found DD"s jscheuer1 2007 response indicating that most browsers will not allow a td to have relative position.
Ok so half heartedly I tried putting my cell inside a table and positioning the text relative to the table. That doesn't work either. So what elements can be used as containers?
Here is my CSS:
/* This is my container*/
#table {
position: relative;
}
/* Begin Member Companies*/
#company a:link{
position: absolute;
top: 84px;
left: 4px;
font-size: 12px;
font-weight: bold;
color: #094054;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-style: italic;
}
The rest of my #company declarations are exactly like a:link, except hover has a little text decoration.
And here is my HTML:
<!-- Absolute Relative Positioning-->
<div id="table">
<td width="207" valign="top"><table width="100%" border="0" cellpadding="0" cellspacing="0">
<!--DWLayoutTable-->
<tr>
<td width="207" height="120" valign="top" background="images/Right_Top.gif">
<div id="company"><a href="http://www.pcpg.org/pcpg_members.html">Member Companies</a></div>
</td>
</tr>
</table>
</td>
</div>
<!--End Absolute Positioning-->
So if tds can't be relatively positioned, what can I use as a container?
Here is the URL for this page. When I open it in either Firefox or IE7 the text "Member Companies" is parsed relative to the document window.
http://www.harrisburgmarathon.com/Z_New/Experiment_ab.asp