Ninjacu
Ninjacu

Reputation: 169

Header cant have a border

border-width doesn't work.

header {
    background-color: #58ACFA;
    text-align: center;
    border-width: 5px;
    border-color: black;
}

I tried to use border-size and it did not work.

How can I do it?

Upvotes: 3

Views: 67

Answers (2)

Blazer
Blazer

Reputation: 14277

header {
    background-color: #58ACFA;
    text-align: center;
    border-style: solid;
    border-width: 5px;
    border-color: black;
}

you prob. forget a border-style. I added it for you. It can also be done on one line

border: 5px solid #000;

Upvotes: 6

Daniel
Daniel

Reputation: 7016

Try:

header {
    background-color: #58ACFA;
    text-align: center;
    border: 5px solid black;
}

Which is the same as

header {
    background-color: #58ACFA;
    text-align: center;
    border-style: solid;
    border-width: 5px;
    border-color: black;
}

Upvotes: 3

Related Questions