• 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

yoyo2008

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
  • Profile
  • Topics Started
  • Replies Created
  • Engagements
  • Favorites

Forum Replies Created

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • February 12, 2017 at 11:37 am in reply to: Displaying logo and tagline/description marked with h2 tag in Magazine Pro child #201001
    yoyo2008
    Participant

    Sorry the only thing I cannot figure it is, finally I have to put the two code snippets in functions.php? Like this?

    add_filter( 'genesis_seo_title', 'filter_title_with_logo', 10, 3 );
    /**
    * @author Brad Dalton
    * @example http://wpsites.net/web-design/add-logo-above-taglinedescription-in-genesis/
    * @copyright 2014 WP Sites
    */
    function filter_title_with_logo( $title, $inside, $wrap ) {
    $inside = sprintf( '%s', trailingslashit( home_url() ), esc_attr( get_bloginfo( 'name' ) ), get_bloginfo( 'name' ) );
    $title = sprintf('<%s class="site-title">%s</%s>', $wrap, $inside, $wrap);
    return sprintf( '<%1$s id="title">%2$s</%1$s>', 'h1', $inside );
    }

    add_filter( 'genesis_site_description_wrap', 'description_h2_wrap' );
    function description_h2_wrap() {
    return 'h2';
    }

    Doing this in my Magazine Pro child theme it now marks h2 the description

    <h2 class="site-description"><?php bloginfo( 'description' ); ?></h2>

    but it didn't shows it.

    February 11, 2017 at 5:28 pm in reply to: Displaying logo and tagline/description marked with h2 tag in Magazine Pro child #200973
    yoyo2008
    Participant

    Oh, thank you Victor! Everything's ok.

    February 11, 2017 at 9:47 am in reply to: Displaying logo and tagline/description marked with h2 tag in Magazine Pro child #200964
    yoyo2008
    Participant

    Thank you very much Victor, I put it at the end of functions.php but a warning came out:

    Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'h2' not found or invalid function name in /var/www/domains/websitename.com/public_html/wp-includes/class-wp-hook.php on line 298 < class="site-description" itemprop="description">This is the tagline

    Do I have to inset that code in a particular point?

  • Author
    Posts
Viewing 3 posts - 1 through 3 (of 3 total)

CTA

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

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2023 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