Website.Technology

A directory of website technologies - submit your website

Select Page

Internet Explorer box model bug

Listing Title:
Internet Explorer box model bug
Listing Category:
Description:

The Internet Explorer box model bug refers to the way in which earlier versions of Internet Explorer handle the sizing of elements in a web page, which differs from the standard way recommended by the W3C for the Cascading Style Sheets language.

As of Internet Explorer 6, the browser supports an alternative rendering mode (called the “standards-compliant mode”) which solves this discrepancy. However, for backward compatibility reasons, all versions still behave in the usual, non-standard way by default.  Internet Explorer for Mac is not affected by this non-standard behavior.

The Cascading Style Sheets (CSS) specification describes how elements of web pages are displayed by graphical browsers. Section 4 of the CSS1 specification defines a “formatting model” that gives block-level elements such as p andblockquote a width and height, and three levels of boxes surrounding it: padding, borders, and margins. While the specification never uses the term “box model” explicitly, the term has become widely used by web developers and web browser vendors.

Before HTML 4 and CSS, very few HTML elements supported both border and padding, so the definition of the width and height of an element was not very contentious. However, it varied depending on the element. The HTML width attribute of a table defined the width of the table including its border. On the other hand, the HTML width attribute of an image defined the width of the image itself (inside any border). The only element to support padding in those early days was the table cell. Width for the cell was defined as “the suggested width for a cell content in pixels excluding the cell padding.”

In 1996, CSS  introduced margin, border and padding for many more elements. It adopted a definition width in relation to content, border, margin and padding similar to that for a table cell. This has since become known as the W3C box model.

At the time, very few browser vendors implemented the W3C box model to the letter. The two major browsers at the time, Netscape 4.0and Internet Explorer 4.0 both defined width and height as the distance from border to border. This has been referred to as thetraditional or the Internet Explorer box model.

9 Most Common IE Bugs

1. Centering a Layout
2. Staircase Effect
3. Double Margin on Floated Elements
4. Inability to Have Elements with Small Heights
5. Auto Overflow and Relatively Positioned Items
6. Fixing the Broken Box Model
7. Setting a Minimum Width and Height
8. Floated Layout Misbehaving
9. Space Between List Items

Send Message to listing owner