Closed Bug 325669 Opened 20 years ago Closed 16 years ago

Some floating div layers are not rendering in their proper position

Categories

(Firefox :: General, defect)

x86
Windows 98
defect
Not set
normal

Tracking

()

RESOLVED INCOMPLETE

People

(Reporter: postmaster, Unassigned)

References

()

Details

User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows 98) Build Identifier: unknown Hi. I'm not a Firefox user. One of my customers sent me a screencap of my site on his screen, to let me know it "looked funny." Sadly, I don't know what version he's running or what OS. The problem appears to be in how the browser handles floating div layers within the main html code. My site uses lots of divs within divs. Some have their position defined in my CSS file, others are designated on the fly. From the screencap he sent, it appears that the divs laid out in the CSS file are displaying correctly, but the divs in the main html code are not. The relevant source code for my index page is as follows: <div id="navbar"> <a href="index.html"> Home </a><br><br> <a href="OrderBook.html"> Buy The Book </a><br><br> etc. </div> ****** The div above is rendered properly as a column on left side of screen <div id="header"><center> <img USEMAP="#banner" src="Banner.JPG" width = "670" height = "144" border="0" alt = "The Fraud Goes Ever On and On..."></center> </div> ****** The div above is rendered properly as a banner at top of screen <div id="content"> This whole section comprises the rest of the screen to the right of the navbar and below the header. It is rendered properly in that position. However, WITHIN THIS DIV, there are problems, read on: <div style="width: 150px; float: left; position: relative; right: 8px;"><center> <img src="images/tinycover.JPG" alt="wee little cover" width="120" height ="184"> <h3><a href="pressrelease.html#chapter"> Read a Chapter! </a></h3> </center> </div> *****This div is apparently rendered correctly as the first element in the Content layer. ************ BUT HERE'S THE PROBLEM: <div style="float: right;"> <div id="white" style="padding:0;"><center> <H2>When A Fan Hits the ****:<br> The Rise and Fall of a Phony Charity</H2></center> </div> ********THIS DIV IS NOT FLOATING. IT IS DISPLAYED BELOW THE FIRST ELEMENT, RATHER THAN TO THE RIGHT OF THE FIRST ELEMENT. <div> In 2003, two obsessed "Lord of the Rings" fans devised a way to meet their favorite celebrities: create a phony charity and invite the stars to host "fundraising events." Meet the stars and pocket the cash--a heist made in heaven! But then they told one lie too many. . . <br> </div> ********************MORE OF THE SAME PROBLEM: THE ABOVE DIV SHOULD EITHER FLOAT TO THE RIGHT OF THE FIRST ELEMENT IF THE WINDOW IS BIG ENOUGH, OR BE DISPLAYED UNDER THE FIRST TWO ELEMENTS IF THE WINDOW IS TOO NARROW. <div id="pocket" style="position: relative; right: 10px;"> <div style="direction: ltr;"> <H3>What People Are Saying About <i>When A Fan</i></h3> <b> Couldn't put it down. It's very funny and incredibly sad.</b> ~ <a href="http://www.john-howe.com/news/more.php?id=101_0_1_0_C" target="_blank">John Howe</a><br><br> ETC. ****** This one seems to render properly, it's supposed to be slightly offset from the right edge of the Content div. But it generally fits up next to that first element as well, unless the window is very narrow. So once again the float is not being processed. As far as I can tell, the divs within the Content section are being displayed just as regular sequential elements; the floats are being ignored. Note that the Header, Navbar and Content sections are all defined in my css file as such: div#header { margin-left: 110px; padding: 5px; height: 145px; } div#navbar { font-family: "Verdana", sans-serif; font-weight: bold; font-size: medium; font-style: italic; position: absolute; left: 5px; top: 10px; width: 150px; } div#content { margin-left: 170px; margin-right: 15px; overflow:auto; height: 400px; } As you can see, the css uses both relative and absolute positioning (but no floats, heh) and appears to be running properly. Well, good luck! I can forward you the screencap from this customer if that will help. Reproducible: Always Actual Results: I have a screencap of the improper rendering that I can forward if you want. Expected Results: Surf to turondo.com from netscape, aol, or IE and you can see what it should look like. I also have a lot of complicated div placement on the page www.turondo.com/Media.html (click on "Online Press Kit.") That one may give you an even more ugly example of the nonfloating floaters. I write my own HTML and try to stay within W3C standards so I would expect Firefox to be able to render it properly. If the issue is in my code, please let me know. Thanks.
Please come up with a minimized testcase that shows the bug. Just because somethign shows up different in IE doesn't mean it's a bug in Firefox. We are not here to help people with their web design problems.
(In reply to comment #1) > Please come up with a minimized testcase that shows the bug. Just because > somethign shows up different in IE doesn't mean it's a bug in Firefox. We are > not here to help people with their web design problems. The test case is to open your browser and type "www.turondo.com" on the URL line. You will see the bug as soon as the page loads. This page loads properly in AOL, Netscape and IE. It conforms to W3C standards. I don't have a web design problem. There is a bug in your browser. Other people have complained about misplaced float elements. I tried to file this as a comment under an existing float bug, and martijn.martijn@gmail.com told me to file this as a new bug report. I took the time to include my source code to help you identify the problem. I do NOT think there is an error in my code because this page loads fine on other browsers. If there is error in my code, I'd appreciate being told, but that was not why I filed this bug. That remark about seeking help for "my design problems" was snotty and out of line.
Still, please attach a minimized testcase. Here's a page that explains what we mean with a minimized testcase: http://www.mozilla.org/newlayout/bugathon.html#testcase On the same page it is explained why the minimized testcases are important. Your site may or may not be displaying correctly by Firefox, but it's really hard to say without a minimized testcase. And about comment 1. Please don't be offended. I think you'd feel the same way if you saw as many 'bugs' with web pages, that turn out to be a problem with the page itself, as Adam did.
Incomplete, not enough information. Reporter, please give the info requested above.
Status: UNCONFIRMED → RESOLVED
Closed: 16 years ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.