I've been trying to center some tabs on a navigation bar in Bootstrap 4 without success. Additionally, I can't seem to shorten the line underneath the tabs either. Any advice or hints would be greatly appreciated. Thank you in advance.
Here is my code:
.nav-tabs>li,
.nav-pills>li {
float: none;
display: inline-block;
*display: inline;
/* ie7 fix */
zoom: 1;
/* hasLayout ie7 trigger */
}
.nav-tabs,
.nav-pills {
text-align: center;
}
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Registration</title;
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css" href="stylesheets/asd.css">
<link rel="stylesheet" href="https://cdn.rawgit.com/twbs/bootstrap/v4-dev/dist/css/bootstrap.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.1.0/js/bootstrap.min.js">
</script>
</head>
<body>
<ul class="nav nav-tabs">
<li class="nav-item"><a data-toggle="tab" class="nav-link active" href="#student">Student</a></li>
<li><a data-toggle="tab" class="nav-link" href="#teacher">Teacher</a></li>
</ul>
</body>
</html>
Any thoughts or suggestions?