I've got a problem with a little project. I have a navigation bar that is a div and I have links inside it, however whenever I resize the page the last two start a new line. I would like the links to stay in a horizontal position and have a scrollbar added to the page. For example, when you are on google and you resize the browser the overflowed content does not start a new line., a scrollbar is added. I have tried using a parent div and setting a minimum width, but neither have worked.
The CSS:
.topBar {
background-color:rgb(161,35,35);
position:relative;
display:inline-block;
width:100%;
text-align:center;
height:40px;
}
.text2 {
font-size:35;
text-decoration:none;
margin-left:4%;
margin-right:4%;
}
.parent {
min-width:100%;
}
And the HTML:
<div class="parent">
<div class="topBar">
<a class="text2" href="placeholder.html">Media Mash</a>
<a class="text2" href="placeholder.html">Film</a>
<a class="text2" href="placeholder.html">Music</a>
<a class="text2" href="placeholder.html">Games</a>
<a class="text2" href="placeholder.html">Books</a>
</div>
</div>