0
How do I center an image in a header? I have a 200x200 image I want to set the sides automatically and at the top of the header
@charset "utf-8";
body {
background-color: black;
}
div#interface {
padding: 15px;
}
/* Divisão da interface*/
div#interface {
width: 1500px;
background-color: white;
margin: -21px auto 0px auto;
}
/* Formataçao Menu*/
nav#menu {
display: block;
}
nav#menu ul {
list-style: none;
text-transform: uppercase;
position: absolute;
top: -20px;
left: 1150px;
}
nav#menu li {
display: inline-block;
background-color: black;
padding: 10px 15px 10px 15px;
margin: 2px;
box-shadow: 0px 0px 3px rgba(255, 255, 255,.5);
}
nav#menu a {
text-decoration: none;
color: white;
}
nav#menu a:hover {
text-decoration: underline;
}
/* Formataçao cabecalho*/
header#cabecalho {
height: 300px;
}
header#cabecalho img#logo {
}
<div id="interface">
<header id="cabecalho">
<hgroup>
<h1>Red Hot Chilli Peppers</h1>
<h2>RHCP</h2>
</hgroup>
<nav id="menu">
<ul>
<li><a href="index.html">Home</a></li>
<li><a href="artists.html">Artists</a></li>
<li><a href="songs.html">Songs</a></li>
<li><a href="albums.html">Albums</a></li>
</ul>
</nav>
<img id="logo" src="https://botw-pd.s3.amazonaws.com/styles/logo-thumbnail/s3/012011/red_hot_chili_peppers.png?itok=7edUsGhl" alt="logo">
</header>
</div>
Only with this short description you can not give an accurate answer. Enter in the question the codes so that we can help you.
– Sam