Jump to content
  • 0

проблема с margin-top


Krote
 Share

Question

1408037m.jpg


<!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=utf-8" />
<link href="style/style.css" rel="stylesheet" type="text/css" />
<title>Верстка</title>
<style>
*{margin:0; padding:0;}
#wrapper{
width:980px;
height:910px;
margin:0 auto;
border:1px solid #000;
}

#header{
height:205px;
background: -webkit-linear-gradient(top, #fff, #e8e9ed);
background: -o-linear-gradient(top, #fff, #e8e9ed);
background: -ms-linear-gradient(top, #fff, #e8e9ed);
background: linear-gradient(top, #fff, #e8e9ed);

}
.logo{margin:50px 0 0 0; border:none;}

.search_div{float:right; margin:65px 50px 0 0;}

.search{background:#fffffd; border:1px solid #000;}

.search_img{margin-left:3px;}

.logo_div{float:left;}

.mini_img{margin-top:;}

.mini_img img{border:none;}


</style>
</head>
<body>
<div id="wrapper" >
<div id="header" >
<div class="logo_div"><a href="/"><img src="img/logo.png" alt="" width="433" height="102" class="logo" /></a></div>


<div class="search_div" >
<p>Поиск по сайту</p>
<input type="text" id="search" class="search" /><input type="image" src="img\search.png" class="search_img" id="input" />
</div>
<div class="mini_img">
<a href="/"><img src="img/home.png" width="11" height="10" alt="" /></a>
<a href="/"><img src="img/message.png" width="11" height="9" alt="" /></a>
<a href="/"><img src="img/tree.png" width="11" height="9" alt="" /></a>
</div>
</div>
</div>
</body>
</html>

Проблема, если задать блоку с маленькими изображениями вверху margin-top, то сьезжает вниз полностью весь header. Как исправить? У блока класс mini_img

Edited by Krote
Link to comment
Share on other sites

2 answers to this question

Recommended Posts

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