Reputation: 101
I'm trying to apply css to my div (questionFrame) I'm woundering why it is not working? See snippet. Could someone help?
#questionFrame {
border: 5px;
border-width: 5px;
border-color: black;
}
<div id="questionFrame">
<span style="color:#0091ea"><p id="date">Date Created</p></span>
<div id="userQuestions"></div>
<center>
<div class="grid-container4">
<a class="waves-effect waves-light btn #00e676 green accent-3" style="width:50%" onclick="grabData()">Proceed</a>
<a class="waves-effect waves-light btn #ef5350 red lighten-1 " style="width:50%">Cancel</a>
</div>
</center>
</div>
Upvotes: 0
Views: 101
Reputation: 406
Did you link it. Use
<link rel="stylesheet" href="YourStylesheet.css">
In the head of your html
Upvotes: -3
Reputation: 48415
The problem is that you have not specified the border style (for example "solid"). You can either do these separately:
#questionFrame {
border: solid;
border-width: 5px;
border-color: black;
}
Or in a single statement:
#questionFrame {
border: 5px solid black;
}
I would recommend that latter.
Upvotes: 3
Reputation: 561
You didn't set any style for your border like border:5px solid;
or border-style:solid;
Here you can read more about the border styles: https://www.w3schools.com/css/css_border.asp
Upvotes: 2
Reputation: 16251
#questionFrame{
border: 5px solid black;
}
<div id="questionFrame" >
<span style="color:#0091ea"><p id="date">Date Created</p></span>
<div id="userQuestions"></div>
<center><div class="grid-container4">
<a class="waves-effect waves-light btn #00e676 green accent-3" style="width:50%" onclick="grabData()">Proceed</a>
<a class="waves-effect waves-light btn #ef5350 red lighten-1 " style="width:50%">Cancel</a>
</div></center>
</div>
border: solid;// not 5px
border-width: 5px;
border-color: black;
Upvotes: 2
Reputation: 2157
Try this
#questionFrame{
border:5px solid #000;
}
Or You can style like this
border: solid;
border-width: 5px;
border-color: black;
Upvotes: 1