WordPress.org

Ready to get started?Download WordPress

Forums

Blog Home and Post Titles (3 posts)

  1. AdamBlue
    Member
    Posted 1 year ago #

    I noticed my blog post titles include the complete title found on the home page. bluegamer.net

    Example: BlueGamer | The Ultimate Hardcore Video Game Blog and Podcast | Weekend in Gaming – Game-a-Palooza Edition

    When it should only be: Weekend in Gaming – Game-a-Palooza Edition

    The homepage title is correct as: BlueGamer | The Ultimate Hardcore Video Game Blog and Podcast

    Contents of my header file:

    <head>
    <meta charset="<?php bloginfo( 'charset' ); ?>" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
    <title><?php bloginfo( 'name' ); ?><?php wp_title( '|' ); ?></title>
    <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
    <?php wp_head(); ?>
    </head>

    Thanks for any help.

  2. L B
    Member
    Posted 1 year ago #

    Try this instead:

    <head>
    <meta charset="<?php bloginfo( 'charset' ); ?>" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
    <?php if( is_front_page() ) { ?>
    <title><?php bloginfo( 'name' ); ?><?php wp_title( '|' ); ?></title>
    <?php } else { ?>
    <title><?php wp_title(); ?></title>
    <?php } ?>
    <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
    <?php wp_head(); ?>
    </head>

  3. AdamBlue
    Member
    Posted 1 year ago #

    That did the trick. Thank you very much!

Topic Closed

This topic has been closed to new replies.

About this Topic