23. Displaying it Properly


#1

https://www.codecademy.com/en/courses/web-beginner-en-6merh/4/3

why always error. it looks like your top padding not 5px


body {
    background-color: #b7d1c4
}

h2 {
    font-family: Verdana;
    font-weight: bold;
    text-align: center;
    padding-top: 25px;
    padding-bottom: 25px;
    color: #acd1b2;
}

img {
    height: 170px;
    width: 170px;
    box-shadow: rgba(0,0,0,0.2) 10px 10px;
    

}

#navbar {
    position: fixed;
    margin-top: -10px;
    left:50%;
    margin-left:-254px;
    
}

#header {
    position: relative;
    top: -10px;
    background-color: #3c4543;
    border-top-left-radius: 15px;
    border-top-right-radius: 15px;
    
}

ul{
    list-style-type: none;
    position: fixed;
    margin: -10px;
    
}

li {
    display: inline;
    
    border: 2px solid #000000;
    font-family: Futura, Tahoma, sans-serif;
    color: #ffffff;
    border-radius: 5px 5px;
    background-color: #cc0323
    
}

#left{
    padding: 5px;
    
}

p {
    font-family: Tahoma;
    font-size: 1em;
    padding: 5px;
}

#right{
    padding: 5px;
    
}

table {
    border: #000000 1px solid;
    background-color: #acd1b2;
    float: right;
    margin-right: 10px;
    border-bottom-right-radius: 15px;
    border-bottom-left-radius: 15px;
    padding: 5px;
}

td {
    height: 75px;
    width: 75px;
    padding: 5px;
}

td img {
    height: 75px;
    width: 75px;
    box-shadow: none;
    padding: 5px;
}

th {
    font-family: Verdana;
    font-size: 1em;
    font-weight: normal;
    color: #3c4543
    padding: 5px;
}

#bottom_left{
    border-bottom-left-radius: 15px;
    padding: 5px;
}

#bottom_right{
    border-bottom-right-radius: 15px;
    padding: 5px;
}

#footer{
    padding: 5px;
    
    position: relative;
    bottom: -20px;
    border-bottom-left-radius: 15px;
    border-bottom-right-radius: 15px;
    height: 75px;
    background-color: #3c4543;
}

#button{
    border: 2px solid #000000;
    float:left;
    position: relative;
    left: 229px;
    bottom: -20px;
    border-radius: 5px;
    background-color: #cc0323;
    height: 30px;
    width: 150px;
    padding: 5px;
}

#button p{
    position: relative;
    bottom: 10px;
    font-size: 0.8em;
    color: #acd1b2;
    text-align: center;
    padding: 5px;
}

.bold{
    font-family: tahoma;
    font-weight: bold;
    font-size: 1.2em;
    font-variant: small-caps;
    color: #ffffff;
    padding: 5px;
}


#2

Set your screen zoom to 100% and try again. Otherwise, please post your code and a link to the exercise.


#3

im done with ctr 0 for screen zoom to 100% but its same "your padding top isn't 5px, where i can put padding top ?


#4

you have to give li a display: inline; and and a padding, you can add it to the li css selector:

li {
    display: inline;
    
    border: 2px solid #000000;
    font-family: Futura, Tahoma, sans-serif;
    color: #ffffff;
    border-radius: 5px 5px;
    background-color: #cc0323
    
}

be aware that after background there is no semi-colon...


#7

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.