[Resolved] Position of the header logo

Home Forums Support [Resolved] Position of the header logo

Home Forums Support Position of the header logo

Viewing 12 posts - 16 through 27 (of 27 total)
  • Author
    Posts
  • #97190
    elguavas

    cool on all counts! πŸ˜‰

    #107349
    Michal

    is there any chance for update on sortable header items, as you’ve Tom in your first reply above? sorry for pushing πŸ˜‰

    #107610
    Tom
    Lead Developer
    Lead Developer

    Have a couple things to get released first, but this is high on my list πŸ™‚

    #108123
    Tom
    Lead Developer
    Lead Developer

    As of 1.2.9.7, we’ll be able to add a function to our child themes and adjust the order of the header items.

    For example: https://gist.github.com/generatepress/d58dd082dbd741943aee

    You would pop that function into your child theme, and then rearrange the items to your liking.

    Again, this won’t work until 1.2.9.7 is live.

    #111620
    teloyrur

    Hi Tom! πŸ™‚

    Firstly, I’m very happy with my purchase of GP Premium, as it seems to do everything that I need, with the possibility of adding a few other things that I’d like..

    I tried the suggestions above but I couldn’t get it to work.

    Now that 1.2.9.8 is out I wonder if you’d be kind enough to detail how I add this:

    https://gist.github.com/generatepress/d58dd082dbd741943aee

    and how I can the use it to move the logo position.

    Thanks in anticipation.

    #111622
    Tom
    Lead Developer
    Lead Developer

    Absolutely!

    Add the entire function to your child theme’s functions.php file, or another method shown at the link below.

    How to add PHP: http://generatepress.com/knowledgebase/adding-php-functions/

    You’ll see the function is made up of three areas:

    // Header widget
    if ( is_active_sidebar('header') ) : ?>
    	<div class="header-widget">
    		<?php dynamic_sidebar( 'header' ); ?>
    	</div>
    <?php endif;
    // Site title and tagline
    if ( empty( $generate_settings['hide_title'] ) || empty( $generate_settings['hide_tagline'] ) ) : ?>
    	<div class="site-branding">
    		<?php if ( empty( $generate_settings['hide_title'] ) ) : ?>
    			<p class="main-title" itemprop="headline"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></p>
    		<?php endif;
    				
    		if ( empty( $generate_settings['hide_tagline'] ) ) : ?>
    			<p class="site-description"><?php bloginfo( 'description' ); ?></p>
    		<?php endif; ?>
    	</div>
    <?php endif;
    // Site logo
    if ( !empty( $generate_settings['logo'] ) ) : ?>
    	<div class="site-logo">
    		<a href="<?php echo apply_filters( 'generate_logo_href' , esc_url( home_url( '/' ) ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><img class="header-image" src="<?php echo $generate_settings['logo']; ?>" alt="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" /></a>
    	</div>
    <?php endif;

    Simple re-arrange these blocks (keeping them intact, as shown above), and you’re good to go!

    #111645
    teloyrur

    Thanks Tom!

    Do I just copy and paste it after this:-

    <?php
    /**
    * Generate child theme functions and definitions
    *
    * @package Generate
    */

    which is the only text showing when I select the php option in “Editor”?

    #111646
    Tom
    Lead Developer
    Lead Developer

    You got it πŸ™‚

    Be sure to paste the entire function: https://gist.github.com/generatepress/d58dd082dbd741943aee

    Then re-arrange as needed.

    #111647
    teloyrur

    That’s brilliant, I’ve managed to move the logo above the site title and tagline without crashing the site but I’d like it positioned to the left of the site title and tagline.

    Sorry for the additional workload Tom.

    #111705
    Tom
    Lead Developer
    Lead Developer

    This CSS from earlier in the thread should do it: http://generatepress.com/forums/topic/position-of-the-header-logo/#post-94233

    #111740
    teloyrur

    Thanks again Tom!

    It works perfectly.

    Very much appreciated!

    #111779
    Tom
    Lead Developer
    Lead Developer

    Awesome! Happy to help πŸ™‚

Viewing 12 posts - 16 through 27 (of 27 total)
  • You must be logged in to reply to this topic.