Nick Gilbert Nick Gilbert - 3 months ago 14
CSS Question

Bootstrap's Outline Buttons Behave like Regular Buttons

I'm trying to use Bootstrap's btn-outline-primary class to make a nice looking button like this

enter image description here

However, when I try and do that in my HTML code

<!DOCTYPE html>
<html lang="en">
<head>
<title></title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
</head>
<body>
<button type="button" class="btn btn-outline-primary">Primary</button>
<button type="button" class="btn btn-outline-primary">Primary</button>
</body>
</html>


The buttons come out solid

enter image description here

and I don't know why. Any help would be greatly appreciated.

Answer

btn-outline-primary is only available in Bootstrap v4 and you have 3.3.7 loaded. Try giving v4 a whirl to see if it works.

See this bootply and switch between 3.3.7 and alpha v4 to demo.