473,240 Members | 1,600 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,240 software developers and data experts.

Default top and bottom margin disappear in IE7: why

[followup-to set to comp.infosystems.www.authoring.html]
Hello fellow HTML and markup coder colleagues,

Please visit this url:

http://www.gtalbot.org/BrowserBugsSe...Disappear.html

I would appreciate it if someone could explain

1- why MSIE 7 render this simple webpage so differently from Firefox
2.0.0.9, Opera 9.50, Safari 3.0.3?

2- If this is due to a bug in MSIE7? If so, which one?

3- When querying the currentStyle of margin-top and margin-bottom of
#OrdinaryPargLime with IE developer toolbar or by querying with
currentStyle.marginTop, the value returned is "auto". When creating a
nested <pwith margin declaratively set to auto inside a div with
Parent-Floated-Yellow-Div class, then the top margin and bottom margin
suddenly occur in MSIE7 but are removed in other browsers (Firefox
2.0.0.9, Opera 9.50, Safari 3.0.3).

What I am trying to say is this: in MSIE 7, the current style values
of margin-top and margin-bottom for #OrdinaryPargLime and for
#OrdinaryPargWithMarginAutoOrange are the exactly the same: auto but
even for MSIE 7, those 2 paragraphs' vertical margins are rendered
very differently.

4- In MSIE 7, paragraphs have default margins. Why are they removed
(at least not visible, not rendered) for #OrdinaryPargLime ?

Best regards,

Gérard
[followup-to set to comp.infosystems.www.authoring.html]

Nov 10 '07 #1
2 4871
On 2007-11-10, GTalbot <ne*******@gtalbot.orgwrote:
[followup-to set to comp.infosystems.www.authoring.html]
Hello fellow HTML and markup coder colleagues,

Please visit this url:

http://www.gtalbot.org/BrowserBugsSe...Disappear.html

I would appreciate it if someone could explain

1- why MSIE 7 render this simple webpage so differently from Firefox
2.0.0.9, Opera 9.50, Safari 3.0.3?

2- If this is due to a bug in MSIE7? If so, which one?
Clearly it is a bug. OrdinaryPargLime should have <p>'s default margins
(usually 1.12em top and bottom, but that's up to the browser), and
OrdinaryPargWithMarginAutoOrange should have no margins because you set
them to auto.

CSS 2.1 10.6.3:

If 'margin-top', or 'margin-bottom' are 'auto', their used value is
0.
3- When querying the currentStyle of margin-top and margin-bottom of
#OrdinaryPargLime with IE developer toolbar or by querying with
currentStyle.marginTop, the value returned is "auto".
So far so good. If the default really is auto, it should render as it
has done-- with no margins.

The first test (OrdinaryPargLime) can be considered "passed but
suspicous"-- because we know really that <pis supposed to have some
default margins.
When creating a nested <pwith margin declaratively set to auto
inside a div with Parent-Floated-Yellow-Div class, then the top margin
and bottom margin suddenly occur in MSIE7 but are removed in other
browsers (Firefox 2.0.0.9, Opera 9.50, Safari 3.0.3).
As they should be.
What I am trying to say is this: in MSIE 7, the current style values
of margin-top and margin-bottom for #OrdinaryPargLime and for
#OrdinaryPargWithMarginAutoOrange are the exactly the same: auto but
even for MSIE 7, those 2 paragraphs' vertical margins are rendered
very differently.
It looks like MSIE7 is very confused.
4- In MSIE 7, paragraphs have default margins. Why are they removed
(at least not visible, not rendered) for #OrdinaryPargLime ?
Who knows? Perhaps it's applying the selector to the wrong <p>. If you
delete the second paragraph altogether perhaps the first one sorts
itself out?
Nov 10 '07 #2
On 10 nov, 05:27, Ben C <spams...@spam.eggswrote:
On 2007-11-10, GTalbot <newsgr...@gtalbot.orgwrote:
[followup-to set to comp.infosystems.www.authoring.html]
Hello fellow HTML and markup coder colleagues,
Please visit this url:
http://www.gtalbot.org/BrowserBugsSe...tomMarginsForP...
I would appreciate it if someone could explain
1- why MSIE 7 render this simple webpage so differently from Firefox
2.0.0.9, Opera 9.50, Safari 3.0.3?
2- If this is due to a bug in MSIE7? If so, which one?

Clearly it is a bug. OrdinaryPargLime should have <p>'s default margins
(usually 1.12em top and bottom, but that's up to the browser), and
OrdinaryPargWithMarginAutoOrange should have no margins because you set
them to auto.

CSS 2.1 10.6.3:

If 'margin-top', or 'margin-bottom' are 'auto', their used value is
0.
[snipped]

I have filed 2 distinct bug report/testcases for this:

http://www.gtalbot.org/BrowserBugsSe...arginAuto.html

http://www.gtalbot.org/BrowserBugsSe...Disappear.html

All other browsers (except IE) pass these 2 tests.

Regards, Gérard

Nov 10 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: Jukka K. Korpela | last post by:
I just noticed that most browsers render <table border="1"><tr><td><p>foo</p></td></tr></table> the same way as <table border="1"><tr><td>foo</td></tr></table> That is, they ignore the p...
5
by: Aaron | last post by:
I have a div with an image which needs to appear in it's bottom left. I currently have the padding top of the image set to 100%, which should move the image to the bottom of the the div, but for...
14
by: Xah Lee | last post by:
is there somewhere i can find the default css for browsers? e.g. what's the usual rendering in terms of css for <p>, <ul> etc. in particular, right now i'm interested in creating a style...
26
by: meltedown | last post by:
I have 2 left floating divs on a page. Sometime the left side is larger, sometimes the right side is larger. I want the page to have a margin at the bottom of whichever div is the largest. If I...
1
by: Edward | last post by:
I created a simple CSS layout (code and example below) for bloggin/writing but ran into five issues that I need help with: 1. How do I get rid of the right-margin red line on the last three...
0
by: GTalbot | last post by:
Hello fellow stylesheet colleagues, Load this url: http://www.gtalbot.org/BrowserBugsSection/DefaultTopBottomMarginsForPargDisappear.html I would appreciate it if someone could explain 1-...
6
by: John Dann | last post by:
Don't know whether anyone might be willing to take a look at a little CSS problem that's stumping me. There's a page fragment at: http://www.weatherstations.co.uk/default_test.htm and the item...
7
by: GTalbot | last post by:
Hello fellow authoring.stylesheets colleagues, Can someone please explain why the bottom margin of the last inflow block-level child in an overflowed parent should not have its margin reachable....
1
by: runway27 | last post by:
i am having a serious issue with ie 7 i really need help. i am using a center layout using 900px the center layout looks and works fine in all browsers except for ie7 i have used a border for...
3
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 3 Jan 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). For other local times, please check World Time Buddy In...
0
by: jianzs | last post by:
Introduction Cloud-native applications are conventionally identified as those designed and nurtured on cloud infrastructure. Such applications, rooted in cloud technologies, skillfully benefit from...
0
by: abbasky | last post by:
### Vandf component communication method one: data sharing ​ Vandf components can achieve data exchange through data sharing, state sharing, events, and other methods. Vandf's data exchange method...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: fareedcanada | last post by:
Hello I am trying to split number on their count. suppose i have 121314151617 (12cnt) then number should be split like 12,13,14,15,16,17 and if 11314151617 (11cnt) then should be split like...
0
by: stefan129 | last post by:
Hey forum members, I'm exploring options for SSL certificates for multiple domains. Has anyone had experience with multi-domain SSL certificates? Any recommendations on reliable providers or specific...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: Aftab Ahmad | last post by:
Hello Experts! I have written a code in MS Access for a cmd called "WhatsApp Message" to open WhatsApp using that very code but the problem is that it gives a popup message everytime I clicked on...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.