Wordpress Themes - WP Forum at BFA
Click here to register or to donate.
Auto self-registration is not available here - far too many spammers. This forum has many, many backlinks and because of that there is an intense desire among spammers to drop their links here.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme »

How to fix non sticking sticky footer with Jquery.

Old May 7, 2012, 01:43 PM
48 posts · Jun 2011
England, United Kingdom
I've had this problem with a few versions of Atahualpa now where the footer stops sticking when selected to stick to the bottom of the screen, I'm not sure what the problem was or what if any plugin is conflicting but it seems to be a common problem. I decided to make a fix and it works perfectly on my site across all up to date browsers.

You can use the jquery script below, in the header or include it in your javascript file if you have one.

	function positionFooter(){
		var padding_top = $("#footer").css("padding-top").replace("px", "");
		var page_height = $(document.body).height() - padding_top;
		var window_height = $(window).height();
		var difference = window_height - page_height;
		if (difference < 0) 
			difference = 0;
			padding: difference + "px 0 0 0"
Its essentially the same as the atahualpa script but this works where the default did.
Old May 8, 2012, 04:50 AM
juggledad's Avatar
23,700 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
doesn't work for me in Safari or firefox on the Mac.

I put it in the ato->Add HTML/CSS Inserts->HTML Inserts: Header and it just displayed the code on the screen. I then surrounded it with '<script type="text/javascript">' and '</script>' and left ato->Style & edit FOOTER->Sticky footer on short pages? set to 'NO' and the footer was not sticky. With it set to 'YES' I get both this code and the atahualpa code and it works fine...but which is working?
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
Old May 8, 2012, 08:02 AM
48 posts · Jun 2011
England, United Kingdom
I have no to sticky footer enabled in ATO, but the footer wasn't sticking, it did at first but must have stopped after a changes and plugins were installed.

I have removed the atahualpa javascript for the sticky footer from the js.php file and used the script above in my own javascript file. I then disabled sticky footer in options, its working in all browsers for me on PC & Mac.

It may be conflicting with other JS for you or even the original sticky footer JS. May not work for all but it fixed it for me after months on changing settings and using different methods.


sticky footer

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Similar Threads
Thread Thread Starter Forum Replies Last Post
Sticky Footer in IE8 not working jodybethw Post-Kicker, -Byline & -Footer 2 Mar 28, 2012 01:59 PM
Sticky page footer not sticking Inblingham Post-Kicker, -Byline & -Footer 1 Mar 6, 2011 04:15 AM
Floating above a sticky footer? pjbfcp Atahualpa 3 Wordpress theme 2 Feb 11, 2011 02:56 PM
Sticky Footer krystyna Post-Kicker, -Byline & -Footer 1 Jul 12, 2009 06:21 AM

All times are GMT -6. The time now is 09:33 AM.

Powered by vBulletin® Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.