Jump to content
  • 0

как пофиксить баг в ИЕ6?


sc@r@bey
 Share

Question

сверстал страницу в слоях, но между контентом и боковыми колонками появляется небольшой пробел в ИЕ6, как пофиксить сей баг?

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional-dtd"> 
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="ru" lang="ru">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1251" />
<link href="css/template_css.css" rel="stylesheet" type="text/css" />

<title>Test</title>
</head>
<body>
<div id="container">
<div id="container-inner">
<div id="header">
HEADER
</div>
<div id="navigation">
NAVIGATION
</div>

<div id="sidebar-right">
SIDEBAR A
</div>

<div id="sidebar-left">
SIDEBAR B
</div>
<div id="content">
<div id="content-inner">
CONTENT
</div>
</div>
<div id="footer">
FOOTER
</div>
</div>
</div>
</body>
</html>

body {
padding: 0px;
margin: 0px;
background-color: #f3f0fb;
}

#container {
margin: 0px auto;
padding: 0px;
width: 1004px;
background: url(../images/bg-r.gif) repeat-y right;
border-left: 3px solid #b86ec9;
border-right: 3px solid #b86ec9;
}

#container-inner {
background: url(../images/bg-l.gif) repeat-y left;
}

#header {
padding : 0px;
margin: 0px;
width: 100%;
background-image: url(../images/head.jpg);
background-repeat: no-repeat;
background-position: top left;
height: 232px;
overflow: hidden;
}

#navigation {
margin: 0px;
padding: 0px;
width: 100%;
background-image: url(../images/menu.jpg);
background-repeat: repeat-x;
background-position: top left;
height: 50px;
overflow: hidden;
}

#sidebar-right {
float: right;
width: 180px;
margin: 0px;
padding: 0px;
overflow: hidden;
background-image: url(../images/p-r.gif);
background-repeat: no-repeat;
background-position: top;
}

#sidebar-left {
float: left;
width: 180px;
margin: 0px;
padding: 0px;
overflow: hidden;
}

#content {
margin: 0px;
padding: 0px;
height: 1%;
overflow: hidden;
background-image: url(../images/c-r.gif);
background-repeat: no-repeat;
background-position: top;
}

#content-inner {
width: 100%;
overflow: hidden;
}

#footer {
clear: both;
margin: 0px;
padding: 0px;
width: 100%;
overflow: hidden;
background-image: url(../images/menu.jpg);
background-repeat: repeat-x;
background-position: top left;
height: 50px;
}

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

  • 0
Если я правильно понял, то появляется пробел в 3px в IE между элементами позиционированными с помощью float?

http://www.positioniseverything.net/explor...hreepxtest.html

совершенно верно, только я не совсем понимаю как это прикрутить к своему коду ^_^

Edited by sc@r@bey
Link to comment
Share on other sites

  • 0

разобрался добавил помогло http://www.positioniseverything.net/piefecta-rigid.html

/*** This is a fix for IE5/Win at the largest text size setting. ***/
/* \*/
* html .#sidebar-right {margin-left: -3px;}
/* */
/*** This is a fix for IE5/Win at the largest text size setting. ***/
/* \*/
* html .#sidebar-left {margin-right: -3px;}
/* */

теперь хочется сделать вертикальное выравнивание пл центру во всех браузерах в #navigation и #footer vertical-align не работает причем во всех браузерах,

а в Opera и Firefox не работает горизонтальное выравнивание по центру в #sidebar-left и #sidebar-right

подскажите?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. See more about our Guidelines and Privacy Policy