• CSS Assistance...
    5 replies, posted
[url]http://-/view/dashboard/[/url] I'm trying to stretch the side-bar to the bottom of the page persistently, not just when there's content there, much like a navigation bar where you can stretch it indefinitely. Could anyone help? I'm not a designer by any means.
I've never been much of a frontend guy, however from past knowledge: You can use "min-height: 100vh" (see [url]http://caniuse.com/#search=vh[/url] for infos on "vh" ) in newer browsers. However since this is a percentage this means e.g. margin top/bottom will cause a scrollbar to appear (because now your sidebar is 100% of viewport height and e.g. has an additional margin of 51px on top - thus a scrollbar appears) How to fix the rest I leave up to you. ---- To be honest the html structure doesn't look that clean, especially because you have the sidebar as child element of the header. This will probably not be nice to work with if you want to use media queries to make this reponsive in a nice way (if this is even the plan)
In all honestly all my knowledge is server side, and back-end php, this is my first 'real try at front-end sadly. Any suggestions or improvements are welcomed I'd like to learn more.
You should be able to use [URL="https://developer.mozilla.org/en-US/docs/Web/CSS/calc"]calc[/URL] to subtract the 51px from the 100vh.
Be wary of calc though as it's not supported in IE10 and down. [url]http://caniuse.com/#feat=calc[/url]
Thanks guys I've fixed my issue now, thank you for the responses :)
Sorry, you need to Log In to post a reply to this thread.