Tagged: x
-
AuthorPosts
-
December 8, 2016 at 6:20 am #1285958
raumfishParticipanthi,
you recommended to use the plugin (https://wordpress.org/plugins/sticky-element/)with .x-sidebar as the sticky element and .x-colophon.bottom as ‘sticky end’. (treat #624798)this works fine, but is there a predefined element (instread of ‘.x-colophon.bottom’) to use as sticky end to stop the sidebar at the sidebar bottom?
thanks for help.
flo.December 8, 2016 at 7:45 am #1286033
ChristianModeratorHey there,
Plugins suggested in our replies are not recommendations and we don’t have support for them. Please contact the plugin author or you might want to contact our trusted partners who caters X setup and customization needs. Please see https://community.theme.co/custom-development/
Thanks.
December 8, 2016 at 9:34 am #1286159
raumfishParticipanto.k.
do you have an idea, how to fix sidebar on its bottom, without plugin.
i already tried this code, you posted on another thread (#184732):Custom > CSS in the Customizer
@media screen and (min-width:979px){ .fixedsidebar { position: fixed; top: 2.5%; right: 17.89%; width: 18%; } }and Custom > JavaScript
$(window).on('scroll', function(){ var sidebar = $('aside.x-sidebar.right'); if ( $( this ).scrollTop() >= $(sidebar).offset().top - 20 ) { console.log('fixed attached'); $( sidebar ).addClass('fixedsidebar'); } else { $( sidebar ).removeClass('fixedsidebar'); } console.log('scrolled'); }); $(window).trigger('scroll'); });on the one hand, it works not very well, would you please have a look: http://neuland.ej-muenchen.de/region-sued/
and on the other hand, the sidebar sticks on its top, not on its bottom.could you please help. thanks very much.
flo.December 8, 2016 at 10:05 am #1286196
RupokMemberHi there,
Let’s update the JavaScript code to following :
jQuery(document).ready(function($) { $(window).scroll(function() { var scrollPos = $(window).scrollTop(), navbar = $('.x-sidebar'); if (scrollPos > 300) { navbar.addClass('fixedsidebar'); } else { navbar.removeClass('fixedsidebar'); } }); });Hope this helps.
December 8, 2016 at 10:14 am #1286207
raumfishParticipantthank a lot. it also doesn’t work well , but it’s no plroblem. i decided to use a plugin yet, cause i have to come to a result.
Anyway, thanks for the support.December 8, 2016 at 10:49 am #1286256
RupokMemberYou are welcome!
Feel free to let us know if you face any other issue. We’ll be happy to assist you.
Cheers!
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-1285958 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
