Adding custom logo instead of blog title and description
-
I’m using The Morning After theme for my website https://www.lets-tread-water.com/. In the Theme Options there is no option to add a custom logo to replace the blog title and description in the header. I need help editing the Header.php code in order to do that.
Here is the Header.php code in its entirety:
<?php /** * The Header for our theme. * * @package WordPress * @subpackage The Morning After */ ?> <!DOCTYPE html> <!--[if IE 7]> <html id="ie7" <?php language_attributes(); ?>> <![endif]--> <!--[if (gt IE 7) | (!IE)]><!--> <html <?php language_attributes(); ?>> <!--<![endif]--> <head> <meta charset="<?php bloginfo( 'charset' ); ?>" /> <title><?php wp_title( '|', true, 'right' ); ?></title> <link rel="profile" href="https://gmpg.org/xfn/11" /> <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" /> <?php $morningafter_options = morningafter_get_theme_options(); ?> <?php wp_head(); ?> </head> <body <?php body_class(); ?>> <div class="container"> <?php do_action( 'before' ); ?> <div id="header" class="column full-width clear-fix"> <div id="logo" class="column first"> <div class="title"> <?php $heading_tag = ( is_home() || is_front_page() ) ? 'h1' : 'h3'; ?> <<?php echo $heading_tag; ?> class="site-title"> <a href="<?php echo home_url( '/' ); ?>"><?php bloginfo( 'name' ); ?></a> </<?php echo $heading_tag; ?>> <div class="site-description desc"><?php bloginfo( 'description' ); ?></div> </div> </div><!-- end logo --> <div id="search_menu" class="column border_left last"> <div id="search" class="column first"> <h3 class="mast4"><?php _e( 'Search','woothemes' ); ?></h3> <div id="search-form"> <form method="get" id="searchform" action="<?php echo home_url( '/' ); ?>/"> <div class="clear-fix"> <label for="s" class="none"><?php _e( 'Search for','woothemes' ); ?>:</label> <input type="text" name="s" id="s" class="search_input" value="<?php the_search_query(); ?>" /> <label for="searchsubmit" class="none"><?php _e( 'Go','woothemes' ); ?></label> <input type="submit" id="searchsubmit" class="submit_input" value="Search" /> </div> </form> </div> </div><!-- end #search --> <ul id="menu" class="clear-fix"> <?php $links = array( array( 'slug' => 'home', 'label' => __( 'Home', 'woothemes' ), ), array( 'slug' => 'about', 'label' => __( 'About', 'woothemes' ), ), array( 'slug' => 'archives', 'label' => __( 'Archives', 'woothemes' ), ), array( 'slug' => 'subscribe', 'label' => __( 'Subscribe', 'woothemes' ), ), array( 'slug' => 'contact', 'label' => __( 'Contact', 'woothemes' ), ), ); foreach ( $links as $order => $link ) { $url = ''; if ( isset( $morningafter_options[$link['slug']] ) ) $url = trim( $morningafter_options[$link['slug']] ); if ( ! in_array( $url, array( '', '#' ) ) ) echo '<li><span class="' . esc_attr( $link['slug'] ) . '"><a href="' . esc_url( $url ) . '">' . $link['label'] . '</a></span></li>' . "\n"; } ?> </ul> </div><!-- end #search_menu --> </div><!-- end #header --> <div id="navigation" class="clear-fix"> <?php wp_nav_menu( array( 'depth' => 6, 'menu_class' => 'nav fl', 'theme_location' => 'primary' ) ); ?> <?php if ( $morningafter_options['show_feed_link'] == "1" ) { ?> <ul class="rss fr"> <li class="sub-rss"><a href="<?php bloginfo( 'rss_url' ); ?>"><?php _e( 'Subscribe to RSS', 'woothemes' ); ?></a></li> </ul> <?php } ?> </div><!-- #navigation -->
What would I have to add/change in this code, and where in the code would it go?
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Adding custom logo instead of blog title and description’ is closed to new replies.