It would be better to set a min-height for the main body instead of using js to adjust the footer top.
It would be better to set a min-height for the main body instead of using js to adjust the footer top.