pinboard header sidebar when scrolling in navigation
-
Hello,
I am using Pinboard theme for my wordpress website (which I don’t want to reveal yet) and I am doing some modifications to layout and design. This venture will be advanced type, because I think it should include some javascript code.
So, I am using plugin called sticky menu (or anything!) for my menu to scroll down with the screen. It is working with no problems. But my wish is, when I scroll down, that my header sidebar (social buttons and search) move to navigation, so they scroll down to. But when on top, I want them to be in header. So, this is somekind of conditional thing.Here is my header.php code:
<!DOCTYPE html> <html <?php language_attributes(); ?>> <head> <meta charset="<?php bloginfo('charset'); ?>" /> <title><?php wp_title(); ?></title> <link rel="profile" href="https://gmpg.org/xfn/11" /> <link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" /> <?php wp_head(); ?> </head> <!DOCTYPE html> <html <?php language_attributes(); ?>> <head> <meta charset="<?php bloginfo('charset'); ?>" /> <title><?php wp_title(); ?></title> <link rel="profile" href="https://gmpg.org/xfn/11" /> <link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" /> <?php wp_head(); ?> </head> <!DOCTYPE html> <html <?php language_attributes(); ?>> <head> <meta charset="<?php bloginfo('charset'); ?>" /> <title><?php wp_title(); ?></title> <link rel="profile" href="https://gmpg.org/xfn/11" /> <link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" /> <?php wp_head(); ?> </head> <body <?php body_class() ?>> <div id="wrapper"> <header id="header"> <<?php pinboard_title_tag( 'site' ); ?> id="site-title"> <?php if ( ( '' != get_header_image() ) && ( false != get_header_image() ) ) : ?> <a href="<?php echo home_url( '/' ); ?>" rel="home"> <img src="<?php header_image(); ?>" alt="<?php bloginfo( 'name' ); ?>" width="<?php echo ( pinboard_get_option( 'retina_header' ) ? absint( get_custom_header()->width / 2 ) : get_custom_header()->width ); ?>" height="<?php echo ( pinboard_get_option( 'retina_header' ) ? absint( get_custom_header()->height / 2 ) : get_custom_header()->height ); ?>" /> </a> <?php endif; ?> <a class="home" href="<?php echo home_url( '/' ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a> </<?php pinboard_title_tag( 'site' ); ?>> <?php if( ! is_active_sidebar( 1 ) ) : ?> <<?php pinboard_title_tag( 'desc' ); ?> id="site-description"><?php bloginfo( 'description' ); ?></<?php pinboard_title_tag( 'desc' ); ?>> <?php endif; ?> <?php get_sidebar( 'header' ); ?> <div class="clear"></div> <nav id="access"> <a class="nav-show" href="#access">Show Navigation</a> <a class="nav-hide" href="#nogo">Hide Navigation</a> <?php wp_nav_menu( array( 'theme_location' => 'primary_nav' ) ); ?> <div class="clear"></div> </nav><!-- #access --> </header><!-- #header -->
Thank you guys for answers in advance and I hope you understand what I want.
- The topic ‘pinboard header sidebar when scrolling in navigation’ is closed to new replies.