Using Bootstrap 3.3.7
I am trying to ensure that my footer always stays at the bottom of the browser window.
I prefer not to use a "sticky footer" as I don't want it to cover any part of my content.
Currently, when there is enough content on the page, the footer looks fine, but on shorter pages, it appears randomly on the screen.
Here is an example of the markup:
<body>
<div class="container">
<div class="row">
<h1>My Page</h1>
<p>Content goes here</p>
</div>
</div>
<footer>
<div class="container">
<div class="row">
<p>Footer content here</p>
</div>
</div>
</footer>
</body>
If there is ample content in the body of the page, everything looks good. However, for shorter pages, the layout gets disrupted.
I am using the default height of the navbar in this case:
<nav class="navbar navbar-static-top navbar-inverse">
</nav>
I have explored various solutions for this issue, but none seem to work effectively. It's surprising why achieving such a simple task has become so complex with Bootstrap. Not everyone prefers a sticky footer!