U
U
Umar Mukhamedaliyev2015-09-23 16:52:50
css
Umar Mukhamedaliyev, 2015-09-23 16:52:50

How to remove the "non-existent" part of the block?

I started building a website for my school, but ran into an unexpected problem. Began to typeset the horizontal navigation bar through

#navigation {
    width: 1022; 
    height: 60px;
    background-color: black;
    box-shadow: 0 0 10px 4px #8b8b7a;
    border-radius: 7px;
    margin: auto;
    margin-top: 40px;    
}

#navigation li {
    float: left;
    width: 144px;
    height: 58px;
    background: #73cde8;
    border: 1px solid red;
    text-align: center;
}

Everything seems to be correct, but in reality something like this a8fcf5b940884eafab451b8078152f9e.PNG
turns out. It turns out that the black piece "ul" on the left does not exist.
And how to remove it does not occur to me. I hope for your help.
PS Do not judge strictly

Answer the question

In order to leave comments, you need to log in

4 answer(s)
E
Evgeny Kornachev, 2015-09-23
@umarishe

padding-left:0
add to #navigation, lists(ul) have non-zero padding on the left by default.

G
Gregory, 2015-09-23
@grigruss

li{margin:0;padding:0;}
This is the standard indent for bulleted lists...

O
Oscar Django, 2015-09-24
@winordie

Don't do bullshit. Use bootstrap

D
Dmitry Kim, 2015-09-23
@kimono

Check margin on ul and li

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question