HighDots Forums  

relative positioning in <td>

Cascading Style Sheets Layout/presentation on the WWW (comp.infosystems.www.authoring.stylesheets)


Discuss relative positioning in <td> in the Cascading Style Sheets forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
yawnmoth
 
Posts: n/a

Default relative positioning in <td> - 10-01-2008 , 07:02 PM






http://www.frostjedi.com/terra/scripts/demo/td-position.html

In Internet Explorer, the "hello, world!" text is on top on the red
box is on the bottom. In Firefox, the "hello, world!" text is on top
and the red box is in the middle.

Internet Explorer's rendition is the preferred rendition. Any idea as
to how to make Firefox's rendition look more like Internet Explorer's?

Thanks!

Reply With Quote
  #2  
Old   
Ben C
 
Posts: n/a

Default Re: relative positioning in <td> - 10-02-2008 , 03:34 AM






On 2008-10-01, yawnmoth <terra1024 (AT) yahoo (DOT) com> wrote:
Quote:
http://www.frostjedi.com/terra/scripts/demo/td-position.html

In Internet Explorer, the "hello, world!" text is on top on the red
box is on the bottom. In Firefox, the "hello, world!" text is on top
and the red box is in the middle.

Internet Explorer's rendition is the preferred rendition. Any idea as
to how to make Firefox's rendition look more like Internet Explorer's?
Put another div inside the td, so it looks like this:

<td height=1000 width=100>
<div style="height: 1000px; position: relative"> <--- new div
<div style="position: absolute; background: red ..." ...

Firefox doesn't allow table cells to establish containing blocks for
positioned descendents.


Reply With Quote
  #3  
Old   
dorayme
 
Posts: n/a

Default Re: relative positioning in <td> - 10-02-2008 , 04:41 AM



In article <slrnge8u6b.3n1.spamspam (AT) bowser (DOT) marioworld>,
Ben C <spamspam (AT) spam (DOT) eggs> wrote:

Quote:
Firefox doesn't allow table cells to establish containing blocks for
positioned descendents.
The *only* browser of mine that does establish a containing block is the
now defunct one of MacIE5! They don't make menschy browsers like that no
more!

<http://dorayme.890m.com/alt/relativelyAbsolute.html>

compared with

<http://dorayme.890m.com/alt/relativelyAbsolute_table.html>

--
dorayme


Reply With Quote
  #4  
Old   
Ben C
 
Posts: n/a

Default Re: relative positioning in <td> - 10-02-2008 , 05:08 AM



On 2008-10-02, dorayme <doraymeRidThis (AT) optusnet (DOT) com.au> wrote:
Quote:
In article <slrnge8u6b.3n1.spamspam (AT) bowser (DOT) marioworld>,
Ben C <spamspam (AT) spam (DOT) eggs> wrote:

Firefox doesn't allow table cells to establish containing blocks for
positioned descendents.

The *only* browser of mine that does establish a containing block is the
now defunct one of MacIE5! They don't make menschy browsers like that no
more!

http://dorayme.890m.com/alt/relativelyAbsolute.html

compared with

http://dorayme.890m.com/alt/relativelyAbsolute_table.html
It works in Konqueror 3.5.9, but not in Opera 9.5.1.

Anyway the spec is arguably ambiguous on this as it says in 9.3.1:

The effect of 'position:relative' on table-row-group,
table-header-group, table-footer-group, table-row,
table-column-group, table-column, table-cell, and table-caption
elements is undefined.

but it really it's talking offsetting, not the side-effect of
establishing containing blocks.

The section about containing blocks doesn't mention any exceptions for
table-cells. It just says "the nearest ancestor"-- it's even supposed to
work for inlines (which can create containing blocks with negative
widths, whatever that's supposed to mean).


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.