Home >Web Front-end >HTML Tutorial >padding is interpreted differently under ie and chrome_html/css_WEB-ITnose
The style sheet has padding: 0px 6px 2px;
The padding displayed under ie7 and ie8 is wider, and chrome is normal
The page defines The first line must add a dtd statement. The result without dtd is that ie6, 7, 8, and 9 render the page in the ie5 way, which is the quirks in document mode after opening f12 in ie7, 8, and 9. model. This mode will cause css box model calculation errors, margin:0 auto; cannot be centered.
can only be centered in body{text-align:center;}, but this will center all the content on the page, so please add dtd
dtd must appear in the first line of the page.
xhtml-dtd:
"http://www.w3.org/TR/xhtml1/DTD /xhtml1-transitional.dtd">
html5-dtd:
It is best to add dtd when writing html css. If it is not compatible, it is more difficult to adjust.
The original poster wrote padding:0px 6px 2px; on what tag does it apply?
For example, tags such as h1-6 p will have default margin padding. The original poster searched for reset css
The pages are all in the background. Because of the iframe, the doctype page scroll bar is used There are many problems, so
After adding doctype, the vertical scroll bar under ie7 fails
The vertical scroll bar is only half, and the following I can’t see the triangle
Paste the code, I guess that’s not the solution.
Post the code or send a picture. . . No picture, no truth. .
.right{
position:absolute; top:66px;
right:0px;
bottom:0px;
left:180px;
z-index :8;
}
.rightmain iframe{
height:100%;
width:100%;
position:absolute;
overflow:auto;
z-index:20;
}
body.module{
overflow:scroll;
overflow-x:hidden;
background-color:#f8f8f8;
height ; , what can you do