• Jetzt anmelden. Es dauert nur 2 Minuten und ist kostenlos!

Hintergrund mit 2 Farben

klopower

Neues Mitglied
Sorry das ich nochmal fragen muss,
Habe mein Header , Nav und content platziert nur habe ich ein problem mit dem Hintergrund.
Es soll nämlich so aussehen

CSS
Code:
* {
margin:0px;
padding:0px;

}
body{

background-color:black;
}
header img, nav{
text-align:center;
border-radius:5px;
margin-top:2.5%;

}
nav{
background-color:yellow;
margin-bottom:2%;
}

header{
margin-left:20%;
width:60%;
background-color:red;
}

header img{
margin-left:10%;
width:80%;
}

.content{


margin: 0 auto;
text-align:center;
font-family: calibri;
background-color:green;
  width:48%;
  line-height:15px;

box-shadow: 0px 0px 44px black;
border-radius: 10px;


}
HTML
HTML:
<!DOCTYPE html>
<html>
<head>
<title> Homepage </title>
<meta charset="utf-8" /> <!-- Unicode -->
<link rel="stylesheet" href="style.css" type="text/css" />
<body>



<header>

<a href="index.html"><img src="http://www.html.de/images/logo.png" class="logo"></a>

<nav class="button1">

<input type="button" onclick="window.location.href = '#';" value="Kontakt">


</nav>
</header>







<section class="content">

<p> Content</p><br>
<br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br>



        </section>


        <footer class="footer">
        <p>Footer</p>
        </footer>



</body>
</head>



</html>
Hintergrund.jpg
 
Zuletzt bearbeitet:
Zurück
Oben