• 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

Removing the hyperlink from the site-title

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 › Removing the hyperlink from the site-title

This topic is: not resolved
  • This topic has 3 replies, 3 voices, and was last updated 9 years, 2 months ago by lilolad.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • August 25, 2016 at 6:47 am #192024
    lilolad
    Member

    Hi,
    I'm using the Altitude Pro theme and am trying get it so that the site-title doesn't have a hyperlink at all. It all shows as normal, but doesn't have a hyperlink.

    Any ideas how to do this?

    Many thanks in advance,
    Matt

    http://visitorchat.co.uk/
    August 25, 2016 at 7:07 am #192026
    Victor Font
    Moderator

    The only way to do what you want is to write a custom function to replace genesis_seo_site_title. This sin't exactly what you want, but it will get you started in the right direction: http://victorfont.com/genesis-seo-schema-site-logo/


    Regards,

    Victor
    https://victorfont.com/
    Call us toll free: 844-VIC-FONT (842-3668)
    Have you requested your free website audit yet?

    August 25, 2016 at 9:24 am #192033
    Genesis Developer
    Member

    In Genesis site-title or tagline is showing by "genesis_seo_site_title" function which is locating in lib/structure/header.php file. It have a filter "genesis_seo_title". Using this filter you can alter the HTML markup for site title. I added following script into my child theme's functions.php file:

    add_filter( 'genesis_seo_title', 'gd_remove_hyperlink_site_title', 10, 3 );
    function gd_remove_hyperlink_site_title( $title, $inside, $wrap ) {
      
      if( ! get_header_image() )
        $title = preg_replace( '/<\/?a[^>]*>/', '', $title );
        
      return $title;
      
    }

    Removing the anchor tag if you are not using the header image option. Used PHP's preg_replace function and removed the hyperlink HTML tag from site title. Lastly I am returning the modified site-title HTML markup for echo.


    Download Genesis Featured Posts Combo Widget | Simple Grid Layouts Plugin for Posts, CPTs and terms
    You can request new tips/help.

    August 26, 2016 at 2:11 am #192061
    lilolad
    Member

    Fantastic, that code worked perfectly in the functions.php
    thanks ever so much for that!

    Matt

  • 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

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