Tagged: x
-
AuthorPosts
-
September 27, 2016 at 5:45 pm #1193058
Missy SParticipantHello,
I was able to hide my logo on all pages until scroll but for some reason it only works after I scroll down and scroll back up. I only need to hide logo on my homepage only until scroll down.
Here is the java script I am using:
/* Transparent Navbar on Scrolling – jQuery */
jQuery(document).ready(function($) {
$(window).scroll(function(){
if ($(this).scrollTop() > 100) {
$(‘.masthead.masthead-inline’).addClass(‘mi-fixed-top’);
} else {
$(‘.masthead.masthead-inline’).removeClass(‘mi-fixed-top’);
}
});
});
/* hide logo until Scrolling – jQuery */
jQuery( function( $ ) {$(document).ready(function(){
$(window).bind(‘scroll’, function(){
$(“.x-brand.text”).toggle($(this).scrollTop() > 200);
});
});});
September 27, 2016 at 5:54 pm #1193065
Missy SParticipantThis reply has been marked as private.September 27, 2016 at 5:59 pm #1193067
Missy SParticipantThis reply has been marked as private.September 27, 2016 at 6:01 pm #1193071
Missy SParticipantThis reply has been marked as private.September 28, 2016 at 1:22 am #1193457
Missy SParticipantHello,
I figured it out. I just needed to add css:
.home .x-brand{
display: none;
}Works beautifully!
But now I have another problem. On my single pages the logo is there but disappears once I scroll down.
September 28, 2016 at 1:45 am #1193476
ChristopherModeratorHi there,
Please remove following code from Customize -> Custom -> JavaScript :
jQuery( function( $ ) { $(document).ready(function(){ $(window).bind('scroll', function(){ $(".x-brand.text").toggle($(this).scrollTop() > 200); }); }); });Thanks.
September 28, 2016 at 2:47 am #1193533
Missy SParticipantHi Christopher,
Your solution worked for my single pages but without the code I no longer have a logo that appears when I scroll down my homepage.
LOL, so now I am back to where I started. Please have another look.
Thank you!
September 28, 2016 at 4:02 am #1193584
Paul RModeratorHi,
Please change your js code to this.
jQuery(function($) { $(window).bind('scroll', function(){ $(".home .x-brand.text").toggle($(this).scrollTop() > 200); }); });Hope that helps.
September 28, 2016 at 4:19 am #1193597
Missy SParticipantPerfect! THANKS PAUL!!!!
September 28, 2016 at 5:09 am #1193643
ThaiModeratorIf you need anything else please let us know.
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-1193058 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
