creativedotdesign / tofino

WordPress boilerplate theme on a modern stack. NPM and Composer.
Other
29 stars 6 forks source link

Fix sticky footer for IE #227

Closed ajellender closed 7 years ago

ajellender commented 7 years ago

Fixes Sticky Footer for IE versions 10+

danimalweb commented 7 years ago

Can you test that your code change works with this scenario:

https://github.com/lambdacreatives/tofino/issues/75

Thanks.

ajellender commented 7 years ago

Yep. Just Tested in IE10, Edge13, Chrome and Safari.

All works as expected with too much and too little page content.

danimalweb commented 7 years ago

@AJEllender I merged this and then reverted it. Can you take another look? We already have some code in header.php and footer.php checking for footer_sticky and adding a div with the class name 'wrapper'. Do we just need to update the class and move the position of the wrapper?

ajellender commented 7 years ago

It's not quite that simple. We either need 2 wrappers (because in IE, height and min-height don't work for flex-direction: column elements unless the element is itself a child of a flex element), or the body needs to get a class that sets it's display property to flex. Either are fine, although I generally try and preserve the body tag with as few extra modifications as possible given that it's already being used to house a number of other classes for Wordpress.

Here is example in most basic form: https://codepen.io/AndrewYadda/pen/bgZjEj

danimalweb commented 7 years ago

I'd prefer just the one wrapper element if possible with whatever adjustments need to be made to the body class. I'm already hooking in a bunch of extras into the body tag in strucutre.scss.