Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Absolute placement of element within table

Status
Not open for further replies.

flourish

Programmer
Jun 11, 2001
4
US
I need to place an element, div or table will work, in the upper right or left hand corner of a table cell. A single page will have several table cells within it that each will contain one of these elements. In IE5.5 all I have to do is set the position of the element absolute, and the desired effect is created. In netscape4.5 and 6, the effects are different. I'm not sure if I need some JavaScript to do this, or if CSS alone will do the trick. Any advice?
 
Set the margins to 0px and it should work the same in NN6 and IE5.5. NN4 is a different story... If you have to support it, I would probably just use javascript to detect the browser and set the position accordingly...
 
Do you mean the margins of the body? I have those set to 0 using the html attributes. Is that what you mean? In Netscape6, my elements are appearing layed over the text after 1 line. In IE my elements are appearing layered over the text on the first line. I want the second behavior. Any clarification?
 
That's odd...I've never seen much difference between absolutely positioned elements in NN6 and IE5.5... Without seeing your code, I guess I'd recommend just throwing a browser-detection script on the page to set the position according to the browser.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top