Home > Article > Web Front-end > Why Does `zoom: 1` Work in Older IE Versions?
Question:
Many HTML elements are modified by the CSS property zoom: 1;. What is the rationale behind this practice, and which issue does it resolve?
Answer:
In Internet Explorer versions 7 and prior, the zoom:1 property sets an internal characteristic known as hasLayout.
The article "On having layout" explains this concept: http://www.satzansatz.de/cssd/onhavinglayout.html. It highlights that "layout" is a Microsoft Internet Explorer concept that affects an element's design, interaction, and response to events.
Specifying zoom:1 (and subsequently hasLayout) is particularly useful for addressing certain bugs in Internet Explorer, such as:
Specific Bug Example:
Inlineブロックがinternet explorer 7,6で機能しない(Inline block doesn't work in internet explorer 7, 6)
The above is the detailed content of Why Does `zoom: 1` Work in Older IE Versions?. For more information, please follow other related articles on the PHP Chinese website!