Can you help?

by 7 replies
8
The title of my wordpress blog is Exercise and Nutrition Tips. I ran a title tag analysis and it includes my description and says my title tag is to big. It shows:
<title>Exercise and Nutrition Tips » Helping people reach their fitness goals</title>

Here is my header.php for <title>
<title>
<?php if ( is_home() ) { ?><?php bloginfo('name'); ?> &raquo; <?php bloginfo('description'); ?><?php } ?>
<?php if ( is_search() ) { ?>Search Results &raquo; <?php bloginfo('name'); ?><?php } ?>
<?php if ( is_author() ) { global $wp_query; $curauth = $wp_query->get_queried_object(); ?>Author Archives &raquo; <?php echo $curauth->nickname; ?> &raquo; <?php bloginfo('name'); ?><?php } ?>
<?php if ( is_single() ) { ?><?php wp_title(''); ?> &raquo; <?php bloginfo('name'); ?><?php } ?>
<?php if ( is_page() ) { ?><?php wp_title(''); ?> &raquo; <?php bloginfo('name'); ?><?php } ?>
<?php if ( is_category() ) { ?><?php single_cat_title(); ?> &raquo; Archive &raquo; <?php bloginfo('name'); ?><?php } ?>
<?php if ( is_year() ) { ?><?php the_time('Y'); ?> &raquo; Archive &raquo; <?php bloginfo('name'); ?><?php } ?>
<?php if ( is_month() ) { ?><?php the_time('F Y'); ?> &raquo; Archive &raquo; <?php bloginfo('name'); ?><?php } ?>
<?php if ( is_day() ) { ?><?php the_time('d F Y'); ?> &raquo; Archive &raquo; <?php bloginfo('name'); ?><?php } ?>
<?php if (function_exists('is_tag')) { if (is_tag()) { ?><?php single_tag_title("", true); ?> &raquo; Tag Archive &raquo; <?php bloginfo('name'); ?><?php } } ?>
</title>

Is there something I should change?
#website design
  • I would just capitalize the first letter of every word. So instead of "Helping people reach their fitness goals" it would be "Helping People Reach Their Fitness Goals"
  • I would like for it to just show Exercise and Nutrition Tips. Is there some way to just have the title recognized as the title and not have the description included.
    • [1] reply
    • Yes.

      Change this:
      <?php if ( is_home() ) { ?><?php bloginfo('name'); ?> &raquo; <?php bloginfo('description'); ?><?php } ?>

      to this:
      <?php if ( is_home() ) { ?><?php bloginfo('name'); ?><?php } ?>

      Omit the &raquo; <?php bloginfo('description'); ?> section.
      • [ 1 ] Thanks
  • Thank You so much. When your new to this everything starts to look the same! Again I appreciate it.
    • [1] reply
    • Anytime Mike, we were all there once. Let me know if you need anything else. Always happy to help fellow warriors.
  • Hi,
    You can store this in a variable and then display it in a head part
    this would reduce the length of your title tag
    • [1] reply
    • The info he is concerned about is already included in a variable. How would this shorten anything?

Next Topics on Trending Feed

  • 8

    The title of my wordpress blog is Exercise and Nutrition Tips. I ran a title tag analysis and it includes my description and says my title tag is to big. It shows: <title>Exercise and Nutrition Tips » Helping people reach their fitness goals</title>