[Resolved] mixed font weight in header

Home Forums Support [Resolved] mixed font weight in header

Home Forums Support mixed font weight in header

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1311784
    Torsten

    Hi,
    I would like to have the first word in the header in bold, the second in normal, defined by font weight, for now the font weight is 700, second word should be 300.
    Can you help?
    Thanks ahead,
    Torsten

    #1311844
    Tom
    Lead Developer
    Lead Developer

    Hi there,

    You would need to filter the output manually like this:

    add_filter( 'generate_site_title_output', function() {
        return sprintf(
            '<%1$s class="main-title" itemprop="headline">
                <a href="%2$s" rel="home">
                    <strong>First-word</strong> Second-word
                </a>
            </%1$s>',
            ( is_front_page() && is_home() ) ? 'h1' : 'p',
            esc_url( apply_filters( 'generate_site_title_href', home_url( '/' ) ) )
        );
    } );

    Let me know if you need more info ๐Ÿ™‚

    #1312325
    Torsten

    Thanks a lot, worked, but I installed an image logo instaed…

    #1312887
    Tom
    Lead Developer
    Lead Developer

    No problem! ๐Ÿ™‚

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.