• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Parent Title everywhere but HOME

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › Parent Title everywhere but HOME

This topic is: resolved

Tagged: parent title

  • This topic has 3 replies, 2 voices, and was last updated 11 years, 7 months ago by Nick Davis.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • February 3, 2015 at 2:18 am #139488
    mario
    Member

    Hello.

    I'm using the Genesis Sample Theme and with much failure, I need to get the parent title to show above all my content with the exception of my home page.

    With the help of other forum posts I've been able to get the parent title to post on all pages, I just can't get it off the home.

    These are my function edits:

    //* ***** PAGE HEADER INFO
    //* Remove the site description
    remove_action( 'genesis_site_description', 'genesis_seo_site_description' );
    
    //* ***** ENTRY HEADER INFO
    //* Remove the entry meta in the entry header (requires HTML5 theme support)
    remove_action( 'genesis_entry_header', 'genesis_post_info', 12 );
    //* Remove the entry title (requires HTML5 theme support)
    remove_action( 'genesis_entry_header', 'genesis_do_post_title' );
    
    //* ***** PARENT TITLE AFTER HEADER
    add_action( 'genesis_after_header', 'cw_title' );
    function cw_title() {
    	global $post;
    	$parent_title = get_the_title( $post->post_parent );
    	echo '<div class="parent-title"><h1>' .$parent_title. '</h1></div>';
    }

    I was trying get something to work using if ( ! is_front_page() ) but with no success.

    I'm new at WP and Genesis and have tried everything short of causing major blood flow.

    Any help would be very, very much appreciated.

    I'm attaching a link to the site I'm working on with the hope it will help.

    Thanks

    http://patomak.styleadvertising.com/
    February 3, 2015 at 2:28 am #139490
    Nick Davis
    Member

    Hi Mario

    Try this maybe?

    https://gist.github.com/nickdavis/424c440bd4f48ca0a4ad


    @iamnickdavis. I share the best new Genesis stuff weekly at GenesisWP.guide
    I also offer Genesis theme setup and Photoshop (PSD) to Genesis conversions

    February 3, 2015 at 8:28 am #139511
    mario
    Member

    Nick, Thanks so much for your help, but it doesn't seem to be working. I thought for sure the || was going to work....

    Wholy Gosh DARN!!! I just changed || to && and it's working.

    Thanks so much Nick for getting me here!!! You rock.

    Here's my official final code incase it helps someone else:

    //* ***** PARENT TITLE AFTER HEADER
    add_action( 'genesis_after_header', 'cw_title' );
    function cw_title() {
    	if ( ! is_front_page() && ! is_home() ) {
    		global $post;
    		$parent_title = get_the_title( $post->post_parent );
    		echo '<div class="parent-title"><h1>' .$parent_title. '</h1></div>';
    	}
    }
    

    Wooohooo

    February 3, 2015 at 1:59 pm #139541
    Nick Davis
    Member

    Glad to have helped 🙂


    @iamnickdavis. I share the best new Genesis stuff weekly at GenesisWP.guide
    I also offer Genesis theme setup and Photoshop (PSD) to Genesis conversions

  • Author
    Posts
Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2026 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble