-
AuthorPosts
-
September 16, 2015 at 8:38 am #390620
Hello,
I am working on this site: http://legendland.hu/wp/
I’d like to make the site’s height until the browser’s edge.
For example here: http://legendland.hu/wp/?s=gggggggggg it’s too short.
I’ve tried to use body min-height= 100% and height= 100% but nothing works.
What should I do?Thanks,
LorianaSeptember 16, 2015 at 9:07 am #390662Hi Loriana,
Thanks for writing in! You can add this under Custom > CSS in the Customizer or in your child theme’s style.css file.
.x-main.full { min-height: 740px; }
Note: you may have to adjust the height value to your liking.
Hope this helps – thanks!
September 22, 2015 at 6:01 am #398577Thank you very much! This is working, but I’d like to ask if there is a way to set the height to be flexible? (Make site height as long as the browser)
September 22, 2015 at 6:20 am #398597Hi There,
Please try the following CSS instead:
.x-main.full { height: 100vh; }
Let us know how it goes!
September 22, 2015 at 6:58 am #398629Thanks, I have tried this method. Now it is too long, does not seem to be flexible. 🙁
September 22, 2015 at 7:48 am #398674Hi Loriana,
You can try this code instead
Please add it under Custom > Javascript in the Customizer.
jQuery(function($) { var $window = $( window ).height(); var $navbar = $('.x-navbar').height(); var $footer = $('.x-colophon.bottom').height(); var $headerlandmark = $('.x-header-landmark').height(); $('.x-container.max.width.offset').height($window-$navbar-$footer-$headerlandmark-113px); });
Hope that helps.
September 22, 2015 at 1:06 pm #399037Thank you for not giving up my request. Much appreciated 🙂
Sadly, nothing happens with the JS.September 22, 2015 at 4:19 pm #399195Hi again,
Please replace the previous code with this one:
jQuery(function($) { var $window = $( window ).height(); var $navbar = $('.x-navbar').height(); var $footer = $('.x-colophon.bottom').height(); var $headerlandmark = $('.x-header-landmark').height(); $('.x-container.max.width.offset').height($window+$navbar+$footer+$headerlandmark+(113)); });
Let us know how this goes!
September 23, 2015 at 2:06 pm #400300Now it became too long as you can see if you search something “cldjslfjdl” for no result.
September 23, 2015 at 4:49 pm #400424Hi Loriana,
You can then try for the Sticky Footer instead of the above code. You can find third party plugins for sticky footer e.g https://wordpress.org/plugins/simple-sticky-footer/
Hope this helps!
September 24, 2015 at 5:52 am #401000Thank you. The one you suggested is not working. I searched for other sticky footer plugins, but nothing solves the problem. It seems like this is a common WordPress problem since years.
September 24, 2015 at 6:26 am #401032Maybe something with the CSS would help, just do not know what should I change here instead of the classes:
http://stackoverflow.com/questions/12361029/how-can-i-get-a-sticky-footer-on-my-wordpress-themeSeptember 24, 2015 at 7:32 am #401072Hi Loriana,
Sorry there should be no px in the code.
Kindly try this again.
jQuery(function($) { var $window = $( window ).height(); var $navbar = $('.x-navbar').height(); var $footer = $('.x-colophon.bottom').height(); var $headerlandmark = $('.x-header-landmark').height(); $('.x-container.max.width.offset').css('min-height', $window-$navbar-$footer-$headerlandmark-118 ); });
Hope that helps.
September 25, 2015 at 10:51 am #544681Oh, finally this code is working 🙂 Thank you very much.
Just a little bit more customization to be perfect. Now it looks fine when I open with the Customizer and a little bit too long when I open alone.September 25, 2015 at 6:32 pm #584660Hi Loriana,
Can you please point me to the page where that you are trying to customize because I can’t seem to find it.
Also, do you mean you want to make the area where there is text aligned to the left narrow so it will go closer to the centered texts?
-
AuthorPosts