Addition of <table> to absolutely positioned <div> causes re-positioning of other absolutely positioned <div>'s

RESOLVED INVALID

Status

()

Core
Layout
RESOLVED INVALID
13 years ago
10 years ago

People

(Reporter: Jon Smith, Unassigned)

Tracking

1.8 Branch
x86
Windows XP
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(URL)

Attachments

(1 attachment)

(Reporter)

Description

13 years ago
User-Agent:       Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; UFindUs.com; .NET CLR 1.1.4322)
Build Identifier: 

When building an HTML document, using CSS for layout, I have used the CSS command 'position:absolute' to position <div> elements within the HTML page.

When a <table> element is added to one of these <div> elements, the subsiquent <div> elements are re-positioned as if they were contained within the <div> that has the <table>.

Reproducible: Always

Steps to Reproduce:
1. Download source of page, saving it locally. (will add as attachment)
2. Edit source in a text editor, removing the HTML comment surrounding the <table> element in the source.
3. Load the edited source into a web browser (such as Firefox).

Actual Results:  
Central <div> element (<div id="fish">) contains the (now uncommented) <table> element, however, the other <div> elements seem to take thier origin point for absolute poistioning (with CSS command 'position:absolute') as the top left corner of the central <div> element (<div id="fish">). In addition to this, they also seem to be contained within the central <div> element (<div id="fish">), as can be inferred from the expansion of the scroll bars (with CSS command 'overflow:auto').


Expected Results:  
Central <div> element (<div id="fish">) should contain the (now uncommented) <table> element, other <div> elements should remain absolutely positioned (with CSS command 'position:absolute') where they are observed when the <table> element is commented.
(Reporter)

Comment 1

13 years ago
sorry, forgot build version:

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8b5) Gecko/20051006 Firefox/1.4.1
(Reporter)

Comment 2

13 years ago
Created attachment 201003 [details]
HTML document of test case
Component: General → Layout
Product: Firefox → Core
QA Contact: general → layout
Version: unspecified → 1.8 Branch
(Reporter)

Updated

13 years ago
Component: Layout → General
Product: Core → Firefox
Version: 1.8 Branch → unspecified
Component: General → Layout
Product: Firefox → Core
Version: unspecified → 1.8 Branch
See your testcase.
Instead of closing the table with </table> you're adding a new table by using <table>
So I think this is invalid.

Comment 4

10 years ago
(In reply to comment #3)
> So I think this is invalid.

Yes, with <table> a completely different DOM is generated. With </table> everything works as expected (IE7, Safari3.1 and Opera9 agree).

-> Invalid.
Status: UNCONFIRMED → RESOLVED
Last Resolved: 10 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.