I am trying to make a vertical navigation bar. I have made a navbar.I want to set it's height to full page but i am not able to do that even when is set height:100% in CSS. I want content like para to be displayed on its left side.
body {
margin: 0;
}
ul {
list-style-type: none;
margin: 0px;
padding: 0px;
width: 200px;
height: 100%;
background-color: grey;
}
ul li {
text-align: center;
background-color: grey;
border-bottom: 1px solid black;
}
ul li a {
font-family: monospace;
color: white;
font-size: 23px;
text-decoration: none;
display: block;
padding: 10px;
pos
}
ul li a:hover {
background-color: white;
color: black;
}
ul li a:active {
background-color: cadetblue;
color: red;
}
div {
display: inline;
}
<ul>
<li><a class="active" href="#home" target="_blank">Home</a></li>
<li><a href="#news" target="_blank">News</a></li>
<li><a href="#contact" target="_blank">Contact</a></li>
<li><a href="#about" tartget="_blank">About</a></li>
</ul>
<div>Lorem ipsum dolor sit, amet consectetur adipisicing elit. Ipsam aspernatur qui tenetur dicta, aperiam harum saepe, fuga quae distinctio corporis quas amet minima magnam, excepturi cupiditate at sunt sit cum.</div>
I tried to change the display: parameter of the unordered list to display:inline and also the display: parameter of div tag to display:inline How do I set the height to full page and also display content on its left side.