-
AuthorPosts
-
March 3, 2016 at 11:00 pm #823003
Hello There,
Please update your code and use this instead:
(function($) { $.fn.scrollBottom = function() { return $(document).height() - this.scrollTop() - this.height(); }; var $el = $('.x-sidebar right>div'); var $window = $(window); $window.bind("scroll resize", function() { var gap = $window.height() - $el.height() - 10; var visibleFoot = 172 - $window.scrollBottom(); var scrollTop = $window.scrollTop() if(scrollTop < 172 + 10){ $el.css({ top: (172 - scrollTop) + "px", bottom: "auto" }); }else if (visibleFoot > gap) { $el.css({ top: "auto", bottom: visibleFoot + "px" }); } else { $el.css({ top: 0, bottom: "auto" }); } }); })(jQuery);
We would loved to know if this has work for you. Thank you.
March 4, 2016 at 11:24 am #823798Thanks for the reply.
No luck unfortunately… will report back if I find a solution
March 4, 2016 at 12:18 pm #823865Any tips how to possibly adapt this code? http://jsfiddle.net/FDv2J/3/
March 4, 2016 at 7:09 pm #824257Hi there,
That code is only applicable for that structure, doable using same idea but for X theme structure. And it’s the reverse of what you’re currently want to achieve. The sample stop scrolling at the top box.
I like to help, but this seems like out of our capability. Maybe this is a good feature to have, I’ll take a note of it 🙂
Thanks!
-
AuthorPosts