Leave a Reply

29 Comments on "Fit to Page (The Standard, Ep. 2)"

Notify of
avatar

zehad khan
Guest
zehad khan
1 year 2 months ago

wow

Pejman Behbahani
Guest
Pejman Behbahani
1 year 2 months ago

but how does it look on IE4 😉

Alexander Varwijk
Guest
Alexander Varwijk
1 year 3 months ago

I had this exact problem and I wasn't looking for a solution yet. Going to implement it straight away : )

Сергей Мочалов
Guest
Сергей Мочалов
1 year 5 months ago

great mini tips, keep going

DuDDiTs
Guest
DuDDiTs
1 year 5 months ago

In the example on codepen need to add "box-sizing: content-box" to #footer. It helps prevert showing scrollbars. Because now #footer has "width: 100%" and "padding: 4px;" and it extends #footer beyond viewport

Hady Tolba
Guest
Hady Tolba
1 year 5 months ago

Can I do 100% instead of 100vh?

Good Parts
Guest
Good Parts
1 year 5 months ago

Great tip. Thank you Sam. 🙂

whatsthatredbuttondo
Guest
whatsthatredbuttondo
1 year 5 months ago

Your linked codepen example in the description does not work for me in chrome.I still get scrollbars..

David Young
Guest
David Young
1 year 5 months ago

So when doing this with a then absolutely positioned footer, the footer will overlap the very bottom piece of content when the window is small enough, unless that main element above the footer is given padding-bottom equal to the height of the footer div? I found myself having to do this to prevent the footer overlapping the main content div. Is that the way it's meant to be done?

Lars Rye Jeppesen
Guest
Lars Rye Jeppesen
1 year 5 months ago

You can set the "100vh" on your content div

Βασίλης Κρικώνης
Guest
Βασίλης Κρικώνης
1 year 5 months ago

Is there a solution for the 100vh issue on iOS Safari being larger than the initial visible height with the top and bottom toolbars?

1 2 3
wpDiscuz