• https://miltenacious.com/

    So my menu bar (which has “Home” and the other upcoming tabs in it) is under my header picture, but I want to put it above the header just like in the original Striker theme. How do I do that?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Theme Author Template Express

    (@danstriker)

    Hello,

    the slider is below the menu but the header image sits above. You can move the header image code below the menu code in the header.php file.

    Thread Starter Mitro

    (@mitro)

    I’m not a code expert, so I’ll screw up if I did this the first time, so how should I go about this?

    Thread Starter Mitro

    (@mitro)

    Here’s the code btw, and I DID mess up the first time

    <title><?php wp_title( ‘|’, true, ‘right’ ); ?></title>
    <link rel=”profile” href=”https://gmpg.org/xfn/11&#8243; />
    <link rel=”pingback” href=”<?php bloginfo( ‘pingback_url’ ); ?>” />
    <!–[if lt IE 9]>
    <script src=”<?php echo get_template_directory_uri(); ?>/js/html5.js” type=”text/javascript”></script>
    <![endif]–>

    <?php wp_head(); ?>
    </head>

    <body <?php body_class(); ?>>

    <div id=”wrap”>

    <div id=”page” class=”hfeed site”>
    <?php do_action( ‘before’ ); ?>
    <header id=”masthead” class=”site-header” role=”banner”>
    <?php get_template_part( ‘inc/socmed’ ); ?>
    <?php if ( get_theme_mod( ‘striker_logo’ ) ) : ?>
    <div class=”site-logo”>
    ” title=”<?php echo esc_attr( get_bloginfo( ‘name’, ‘display’ ) ); ?>” rel=”home”><img src=”<?php echo get_theme_mod( ‘striker_logo’ ); ?>” alt=”<?php echo esc_attr( get_bloginfo( ‘name’, ‘display’ ) ); ?>”>
    </div>
    <?php else : ?>

    <div class=”site-introduction”>
    <h1 class=”site-title”>” title=”<?php echo esc_attr( get_bloginfo( ‘name’, ‘display’ ) ); ?>” rel=”home”><?php bloginfo( ‘name’ ); ?></h1>
    <h2 class=”site-description”><?php bloginfo( ‘description’ ); ?></h2>
    </div>
    <?php endif; ?>

    <?php $header_image = get_header_image();
    if ( ! empty( $header_image ) ) { ?>
    ” title=”<?php echo esc_attr( get_bloginfo( ‘name’, ‘display’ ) ); ?>” rel=”home”>
    <img src=”<?php header_image(); ?>” width=”<?php echo get_custom_header()->width; ?>” height=”<?php echo get_custom_header()->height; ?>” alt=”” />

    <?php } // if ( ! empty( $header_image ) ) ?>

    <nav role=”navigation” class=”site-navigation main-navigation”>
    <h1 class=”assistive-text”><?php _e( ‘Menu’, ‘striker’ ); ?></h1>
    <div class=”assistive-text skip-link”>“><?php _e( ‘Skip to content’, ‘striker’ ); ?></div>

    <?php wp_nav_menu( array( ‘theme_location’ => ‘primary’ ) ); ?>
    </nav><!– .site-navigation .main-navigation –>
    </header><!– #masthead .site-header –>

    <div id=”main” class=”site-main”>

    Theme Author Template Express

    (@danstriker)

    This is the entire code:

    <?php
    /**
     * The Header for our theme.
     *
     * Displays all of the <head> section and everything up till <div id="main">
     *
     * @package Striker
     * @since Striker 1.3
     */
    ?><!DOCTYPE html>
    <!--[if IE 8]>
    <html id="ie8" <?php language_attributes(); ?>>
    <![endif]-->
    <!--[if !(IE 8) ]><!-->
    <html <?php language_attributes(); ?>>
    <!--<![endif]-->
    <head>
    <meta charset="<?php bloginfo( 'charset' ); ?>" />
    <meta name="viewport" content="width=device-width" />
    
    <title><?php wp_title( '|', true, 'right' ); ?></title>
    <link rel="profile" href="https://gmpg.org/xfn/11" />
    <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
    <!--[if lt IE 9]>
    <script src="<?php echo get_template_directory_uri(); ?>/js/html5.js" type="text/javascript"></script>
    <![endif]-->
    
    <?php wp_head(); ?>
    </head>
    
    <body <?php body_class(); ?>>
    
    <div id="wrap">
    
    <div id="page" class="hfeed site">
    	<?php do_action( 'before' ); ?>
    	<header id="masthead" class="site-header" role="banner">
         <?php get_template_part( 'inc/socmed' ); ?>
        <?php if ( get_theme_mod( 'striker_logo' ) ) : ?>
        <div class="site-logo">
            <a href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><img src="<?php echo get_theme_mod( 'striker_logo' ); ?>" alt="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>"></a>
        </div>
    <?php else : ?>
    
    		<div class="site-introduction">
    			<h1 class="site-title"><a href="<?php echo home_url( '/' ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>
    			<h2 class="site-description"><?php bloginfo( 'description' ); ?></h2>
    		</div>
    <?php endif; ?>
    
    		<nav role="navigation" class="site-navigation main-navigation">
    			<h1 class="assistive-text"><?php _e( 'Menu', 'striker' ); ?></h1>
    			<div class="assistive-text skip-link"><a href="#content" title="<?php esc_attr_e( 'Skip to content', 'striker' ); ?>"><?php _e( 'Skip to content', 'striker' ); ?></a></div>
    
    			<?php wp_nav_menu( array( 'theme_location' => 'primary' ) ); ?>
    		</nav><!-- .site-navigation .main-navigation -->
    
         <?php $header_image = get_header_image();
    		if ( ! empty( $header_image ) ) { ?>
    			<a href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home">
    				<img src="<?php header_image(); ?>" width="<?php echo get_custom_header()->width; ?>" height="<?php echo get_custom_header()->height; ?>" alt="" />
    			</a>
    		<?php } // if ( ! empty( $header_image ) ) ?>
    
    	</header><!-- #masthead .site-header -->
    
    	<div id="main" class="site-main">
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘How do I move the menu bar?’ is closed to new replies.