Community Forums › Forums › Archived Forums › Design Tips and Tricks › Adding Image to header in Mocha Theme
This topic is: not resolved
- This topic has 2 replies, 3 voices, and was last updated 10 years, 6 months ago by liannef.
Viewing 3 posts - 1 through 3 (of 3 total)
-
AuthorPosts
-
August 28, 2013 at 11:37 pm #59422PIUMember
I apologize if this has been answered already but I searched and couldn't find anything related. I'm trying to add a clients image to the header in Mocha Theme but can't find where to add the code. I see where to add the regular text but I would rather add their logo instead.
Thanks in advance.
http://www.poleitup.com (it is currently in coming soon mode so you can't see it anyways)
August 28, 2013 at 11:54 pm #59432Sridhar KatakamParticipantThe following method works great. I tried in several other Genesis themes.
If you have any questions implementing that, post here.
October 30, 2013 at 11:51 am #69936liannefMemberI put the code in my blog but nothing showed up from using the code. Did I put it in the wrong place?
<?php /** Start the engine */ include_once( get_template_directory() . '/lib/init.php' ); /** Child theme (do not remove) */ define( 'CHILD_THEME_NAME', 'Mocha Theme' ); define( 'CHILD_THEME_URL', 'http://my.studiopress.com/themes/mocha' ); /** Create additional color style options */ add_theme_support( 'genesis-style-selector', array( 'mocha-blue' => 'Blue', 'mocha-green' => 'Green', 'mocha-orange' => 'Orange', 'mocha-pink' => 'Pink' ) ); /** Add Viewport meta tag for mobile browsers */ add_action( 'genesis_meta', 'mocha_add_viewport_meta_tag' ); function mocha_add_viewport_meta_tag() { echo '<meta name="viewport" content="width=device-width, initial-scale=1.0"/>'; } /** Register default layout setting */ genesis_set_default_layout( 'sidebar-content-sidebar' ); /** Unregister content/sidebar layout setting */ genesis_unregister_layout( 'content-sidebar-sidebar' ); genesis_unregister_layout( 'sidebar-sidebar-content' ); /** Add support for custom header */ /* add_theme_support( 'genesis-custom-header', array( 'width' => 960, 'height' => 155 ) ); */ /** Add support for custom background */ add_theme_support( 'custom-background' ); /** Add support for structural wraps */ add_theme_support( 'genesis-structural-wraps', array( 'header', 'nav', 'subnav', 'inner', 'footer-widgets', 'footer' ) ); /** Customize the post info function */ add_filter( 'genesis_post_info', 'post_info_filter' ); function post_info_filter($post_info) { if (!is_page()) { $post_info = 'Posted on [post_date] · [post_comments] [post_edit]'; return $post_info; }} /** Add the after post section */ add_action( 'genesis_after_post_content', 'mocha_after_post' ); function mocha_after_post() { if ( ! is_singular( 'post' ) ) return; genesis_widget_area( 'after-post', array( 'before' => '<div class="after-post widget-area">', ) ); } /** Add support for 3-column footer widgets */ add_theme_support( 'genesis-footer-widgets', 3 ); /** Register widget areas */ genesis_register_sidebar( array( 'id' => 'after-post', 'name' => __( 'After Post', 'mocha' ), 'description' => __( 'This is the after post section.', 'mocha' ), ) );
-
AuthorPosts
Viewing 3 posts - 1 through 3 (of 3 total)
- The forum ‘Design Tips and Tricks’ is closed to new topics and replies.