[thelist] CSS Positioning

Gerenday, Perry (P.) pgerenda at visteon.com
Thu Nov 29 15:36:49 CST 2001


-----Original Message-----
From: JTocher [mailto:discosys at bellsouth.net]
 

 > I am working on an 'interactive map'
...
 > A simplified version of the page can be seen at the following:
 > 
 > http://averra.com/mstest/maps/index_tst.htm
 > 
 > Rollover the term 'Apalachia' in the list to the right. This 
 > displays a
 > yellow box (<div id="locate">&nbsp;</div>) on the map. Fine 
 > 'n dandy until I
 > increase the browser display font size.
 > 
 > So, I'm looking for a way to absolutely position my css generated box
 > relative to the map image - rather than the page.
 > 
 > Seems I should be able to use the 'table cell' as a 'parent' 
 > which will
 > result in the position being relative to the top left corner 
 > of the table
 > cell - yes? However, run into other probs when trying to put 
 > my <div> tag in
 > the cell with the image.


Hi Janice,

What problem are you running into? I did a test of my own and was surprised
to see that both IE5 and NN4.0 allowed me to relatively position a DIV
inside a table cell. The DIV's relative position was affected by the TD
alignment values but nothing else adverse happened. Take a look at this:

<table width="500" cellpadding="0" Cellspacing="0" border="2"
bgcolor="#559955" align="center">
  <tr>
    <td valign="top" height="200">
      <div id="locator"
           style="position:relative; top:10px; left:10px;
			  width:25px; height:25px;
			  border:solid 2px #ffff00;">&nbsp;</div>
    </td>
  </tr>
</table>

I didn't check to see what happens if there is an image inside the table
cell along with the DIV. Is that what the trouble is? Perhaps you can set
the map image as the background to the table.

Perry Gerenday - Web "Deezyner" :)
www.virtually-artistic.com
 




More information about the thelist mailing list