mercredi 28 décembre 2016

CSS Background placement

.container {
    width: 800 px;
    margin: 0 auto;
}
#main {
    background: url(images/header_slice.jpg) repeat-x;
}
#main.container {
    background: url(images/header.jpg) no-repeat;
}
#sidebar {
    float: left;
}
#sidebar h3 {
    font-size: 24px;
    color: #044055;
    font-weight: normal;
}
#sidebar ul li a {
    font-size: 14px;
    color: #393838;
}
ul#subscribe li a {
    font-size: 18px;
    padding-left: 30px;
}
#sidebar ul {
    list-style: none;
}
#sidebar {
    float: left;
    margin-left: 155px;
    margin-top: 35px;
    background: #d4d6d3;
    border: 1px solid #BEBDBD;
    padding: 15px 15px 30px 30px;
}
#sidebar h3 {
    font-size: 24px;
    color: #044055;
    font-weight: normal;
    padding-bottom: 20px;
    padding-left: 15px;
}
#sidebar ul {
    list-style: none;
    padding-bottom: 25px;
}
#sidebar ul li a {
    font-size: 14px;
    color: #393838;
}
ul#subscribe li {
    padding-bottom: 5px;
}
ul#subscribe li a {
    font-size: 16px;
    padding-left: 40px;
}
ul#subscribe li {
    padding-bottom: 5px;
    padding-left: 35px;
}
li#rss {
    background: url(images/rss_icon.png) no-repeat;
    background-size: 20px;
}
li#email {
    background: url(images/email_icon.png) no-repeat;
    background-size: 20px;
}
li#twitter {
    background: url(images/twitter_icon.png) no-repeat;
    background-size: 20px;
}

I was learning how to make a basic website from: http://ift.tt/1h19RSO The header background from the container isn't loading.

enter image description here

Also the the sidebar icons are being overlapped by the text. I tried adding padding in the sidebar anchor but it didn't work. What am I doing wrong?




Aucun commentaire:

Enregistrer un commentaire