Jump to content
  • 0

Неправильное отображение в Opera


epog333
 Share

Question

В Mozilla сайт отображается так (то есть всё хорошо):

7eeaf5108ea74b2ef1d524a7a57aa08a.png

Сайдбар как положено находится на своём месте.

А теперь опера:

01c571b08b006bba29f9b969aa77ddfe.png

Как видите сайдбар уполз вниз и влево.

Вот код CSS:

* {
margin: 0;
padding: 0;
}
body {
font: 12px/18px Arial, Tahoma, Verdana, sans-serif;
width: 100%;
background-image: url('img/1.gif');
}
a {
color: blue;
outline: none;
text-decoration: none;
}
a:hover {
text-decoration: none;
}
p {
margin: 0 0 18px
}
img {
border: none;
}
input {
vertical-align: middle;
}
#wrapper {
width: 1250px;
margin: 0 auto;
}


/* Header
—————————————————————————--*/
#header {
height: 100px;
}

#logo {
margin-top: 15px;
}

#block {
border: 5px solid #eeeeee;
margin-top: 15px;
border-radius:6px;
-webkit-border-radius:6px;
-moz-border-radius:5px;
-khtml-border-radius:10px;
}

/* Middle
—————————————————————————--*/
#middle {
width: 100%;
height: 1%;
position: relative;
}

#tb {
background-image: url('img/1_01.png');
width: 220px;
height: 15px;
padding: 10px;
background-repeat: no-repeat;
font-family: Verdana;
font-size: 16px;
color: #767676;
border-bottom: 5px solid #eeeeee;
}

#title_text {
font-family: Verdana;
font-size: 16px;
color: #767676;
margin-bottom: 1px;
}

#title_text a:hover {
border-bottom: 1px dashed #767676;
}

#mb {
background-image: url('img/1_02.png');
width: 250px;
background-repeat: repeat-y;
font-family: Verdana;
font-size: 12px;
color: #3d3d3d;
padding: 10px;

}

#bb {
background-image: url('img/1_03.png');
width: 250px;
height: 10px;
background-repeat: no-repeat;
margin-bottom: 10px;
}


#middle:after {
content: '.';
display: block;
clear: both;
visibility: hidden;
height: 0;
}
#container {
width: 100%;
float: left;
overflow: hidden;
background-color: white;
border-radius:6px;
-webkit-border-radius:6px;
-moz-border-radius:5px;
-khtml-border-radius:10px;
padding: 10px;
border: 5px solid #eeeeee;
}
#content {
padding: 0 270px 0 0;
margin-top: 10px;
font-family: Verdana;
font-size: 12px;
color: #2e2e2e;
}

#zapis {
border-bottom: 1px dashed gray;
margin-bottom: 15px;
}

#zapis_info {
color: #767676;
font-family: Verdana;
font-size: 11px;
margin-bottom: 5px;

}
/* Sidebar Right
—————————————————————————--*/
#sideRight {
float: left;
margin-right: -3px;
width: 250px;
margin-left: -260px;
position: relative;
}


/* Footer
—————————————————————————--*/
#footer {
height: 100px;
padding: 20px;
}

А вот HTML:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=windows-1251" />
<title></title>
<link rel="stylesheet" href="style.css" type="text/css" media="screen, projection" />
</head>

<body>

<div id="wrapper">

<div id="header">
<div id="logo"><a href="/" ><img src="img/logo.png" /></a></div>
</div><!-- #header-->

<div id="middle">

<div id="container">
<div id="content">
<div id="title_text"><a href="/" id="title_text">Название записи</a></div>
<div id="zapis_info">Дата: 08.04.2011 | Коментарии: 0 | Просмотров: 10</div>
<div id="zapis"><strong>Content:</strong> Sed placerat accumsan ligula. Aliquam felis magna, congue quis, tempus eu, aliquam vitae, ante. Cras neque justo, ultrices at, rhoncus a, facilisis eget, nisl. Quisque vitae pede. Nam et augue. Sed a elit. Ut vel massa. Suspendisse nibh pede, ultrices vitae, ultrices nec, mollis non, nibh. In sit amet pede quis leo vulputate hendrerit. Cras laoreet leo et justo auctor condimentum. Integer id enim. Suspendisse egestas, dui ac egestas mollis, libero orci hendrerit lacus, et malesuada lorem neque ac libero. Morbi tempor pulvinar pede. Donec vel elit.
<strong>Content:</strong> Sed placerat accumsan ligula. Aliquam felis magna, congue quis, tempus eu, aliquam vitae, ante. Cras neque justo, ultrices at, rhoncus a, facilisis eget, nisl. Quisque vitae pede. Nam et augue. Sed a elit. Ut vel massa. Suspendisse nibh pede, ultrices vitae, ultrices nec, mollis non, nibh. In sit amet pede quis leo vulputate hendrerit. Cras laoreet leo et justo auctor condimentum. Integer id enim. Suspendisse egestas, dui ac egestas mollis, libero orci hendrerit lacus, et malesuada lorem neque ac libero. Morbi tempor pulvinar pede. Donec vel elit.

<strong>Content:</strong> Sed placerat accumsan ligula. Aliquam felis magna, congue quis, tempus eu, aliquam vitae, ante. Cras neque justo, ultrices at, rhoncus a, facilisis eget, nisl. Quisque vitae pede. Nam et augue. Sed a elit. Ut vel massa. Suspendisse nibh pede, ultrices vitae, ultrices nec, mollis non, nibh. In sit amet pede quis leo vulputate hendrerit. Cras laoreet leo et justo auctor condimentum. Integer id enim. Suspendisse egestas, dui ac egestas mollis, libero orci hendrerit lacus, et malesuada lorem neque ac libero. Morbi tempor pulvinar pede. Donec vel elit.
<strong>Content:</strong> Sed placerat accumsan ligula. Aliquam felis magna, congue quis, tempus eu, aliquam vitae, ante. Cras neque justo, ultrices at, rhoncus a, facilisis eget, nisl. Quisque vitae pede. Nam et augue. Sed a elit. Ut vel massa. Suspendisse nibh pede, ultrices vitae, ultrices nec, mollis non, nibh. In sit amet pede quis leo vulputate hendrerit. Cras laoreet leo et justo auctor condimentum. Integer id enim. Suspendisse egestas, dui ac egestas mollis, libero orci hendrerit lacus, et malesuada lorem neque ac libero. Morbi tempor pulvinar pede. Donec vel elit.
<strong>Content:</strong> Sed placerat accumsan ligula. Aliquam felis magna, congue quis, tempus eu, aliquam vitae, ante. Cras neque justo, ultrices at, rhoncus a, facilisis eget, nisl. Quisque vitae pede. Nam et augue. Sed a elit. Ut vel massa. Suspendisse nibh pede, ultrices vitae, ultrices nec, mollis non, nibh. In sit amet pede quis leo vulputate hendrerit. Cras laoreet leo et justo auctor condimentum. Integer id enim. Suspendisse egestas, dui ac egestas mollis, libero orci hendrerit lacus, et malesuada lorem neque ac libero. Morbi tempor pulvinar pede. Donec vel elit.
</div>
<div id="title_text"><a href="/" id="title_text">Название записи</a></div>
<div id="zapis_info">Дата: 08.04.2011 | Коментарии: 0 | Просмотров: 10</div>
<div id="zapis"><strong>Content:</strong> Sed placerat accumsan ligula. Aliquam felis magna, congue quis, tempus eu, aliquam vitae, ante. Cras neque justo, ultrices at, rhoncus a, facilisis eget, nisl. Quisque vitae pede. Nam et augue. Sed a elit. Ut vel massa. Suspendisse nibh pede, ultrices vitae, ultrices nec, mollis non, nibh. In sit amet pede quis leo vulputate hendrerit. Cras laoreet leo et justo auctor condimentum. Integer id enim. Suspendisse egestas, dui ac egestas mollis, libero orci hendrerit lacus, et malesuada lorem neque ac libero. Morbi tempor pulvinar pede. Donec vel elit.
<strong>Content:</strong> Sed placerat accumsan ligula. Aliquam felis magna, congue quis, tempus eu, aliquam vitae, ante. Cras neque justo, ultrices at, rhoncus a, facilisis eget, nisl. Quisque vitae pede. Nam et augue. Sed a elit. Ut vel massa. Suspendisse nibh pede, ultrices vitae, ultrices nec, mollis non, nibh. In sit amet pede quis leo vulputate hendrerit. Cras laoreet leo et justo auctor condimentum. Integer id enim. Suspendisse egestas, dui ac egestas mollis, libero orci hendrerit lacus, et malesuada lorem neque ac libero. Morbi tempor pulvinar pede. Donec vel elit.

<strong>Content:</strong> Sed placerat accumsan ligula. Aliquam felis magna, congue quis, tempus eu, aliquam vitae, ante. Cras neque justo, ultrices at, rhoncus a, facilisis eget, nisl. Quisque vitae pede. Nam et augue. Sed a elit. Ut vel massa. Suspendisse nibh pede, ultrices vitae, ultrices nec, mollis non, nibh. In sit amet pede quis leo vulputate hendrerit. Cras laoreet leo et justo auctor condimentum. Integer id enim. Suspendisse egestas, dui ac egestas mollis, libero orci hendrerit lacus, et malesuada lorem neque ac libero. Morbi tempor pulvinar pede. Donec vel elit.
<strong>Content:</strong> Sed placerat accumsan ligula. Aliquam felis magna, congue quis, tempus eu, aliquam vitae, ante. Cras neque justo, ultrices at, rhoncus a, facilisis eget, nisl. Quisque vitae pede. Nam et augue. Sed a elit. Ut vel massa. Suspendisse nibh pede, ultrices vitae, ultrices nec, mollis non, nibh. In sit amet pede quis leo vulputate hendrerit. Cras laoreet leo et justo auctor condimentum. Integer id enim. Suspendisse egestas, dui ac egestas mollis, libero orci hendrerit lacus, et malesuada lorem neque ac libero. Morbi tempor pulvinar pede. Donec vel elit.
<strong>Content:</strong> Sed placerat accumsan ligula. Aliquam felis magna, congue quis, tempus eu, aliquam vitae, ante. Cras neque justo, ultrices at, rhoncus a, facilisis eget, nisl. Quisque vitae pede. Nam et augue. Sed a elit. Ut vel massa. Suspendisse nibh pede, ultrices vitae, ultrices nec, mollis non, nibh. In sit amet pede quis leo vulputate hendrerit. Cras laoreet leo et justo auctor condimentum. Integer id enim. Suspendisse egestas, dui ac egestas mollis, libero orci hendrerit lacus, et malesuada lorem neque ac libero. Morbi tempor pulvinar pede. Donec vel elit.

</div>
</div><!-- #content-->
</div><!-- #container-->

<div class="sidebar" id="sideRight">
<div id="block">
<div id="tb">Название блока</div>
<div id="mb">Содержание</div>
</div>
</div><!-- .sidebar#sideRight -->

</div><!-- #middle-->

<div id="footer">
<img src="http://top100-images.rambler.ru/top100/banner-88x31-rambler-green2.gif" />
</div><!-- #footer -->

</div><!-- #wrapper -->

</body>
</html>

Link to comment
Share on other sites

9 answers to this question

Recommended Posts

  • 0

Попробуй поиграться с шириной среднего контейнера, поделать её меньше.

Спасибо за совет, попробую.

Жесть, кода то сколько)

Не понял эту фразу

уменьшение ширины не помогает

Link to comment
Share on other sites

  • 0

Тебе нужно правильный отступ подогнать для всех, вот у этого контейнера

<div class="sidebar" id="sideRight" style="margin-left: -290px;">

Вот так например в Хроме пашет.

Спасибо, буду пробывать

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