Results 1 to 7 of 7

Thread: Two H1 Headers Clashing on My Home Page. How to Solve This??

  1. #1
    rome9t9's Avatar
    rome9t9 is offline No Longer Loves SEO
    Join Date
    Mar 2009
    Location
    If I tell you, I would have to kill you.
    Posts
    614
    Blog Entries
    4
    Thanks
    168
    Thanked 105 Times in 77 Posts

    Two H1 Headers Clashing on My Home Page. How to Solve This??

    Hello there,
    I am using the arrastheme and by default the site title is in H1 tag in the home page. In posts pages the the post title is in H1 while the site title reduces to span class.

    Now my problem is that the front page of my site is one of my blog posts because I wanted to keep it that way. Now there are two H1 tags in the home page. One is the site title and the other is the post title.

    Its not good for the site's SEO and I want the post title to show in H3 instead of H1. How can I do it??

    Also, I believe the header has lots of junk..please tell me how can I clean it up as I want my site to load faster.

    Here is the header.php of the theme:



    PHP Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>>
    <head profile="http://gmpg.org/xfn/11">
    <meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" />
    <title><?php arras_document_title() ?></title>
    <?php arras_document_description() ?>
    <?php 
    if ( is_search() || is_author() ) : ?>
    <meta name="robots" content="noindex, nofollow" />
    <?php endif ?>

    <?php arras_alternate_style() ?>

    <?php if ( ($feed arras_get_option('feed_url') ) == '' ) : ?>
    <link rel="alternate" type="application/rss+xml" href="<?php bloginfo('rss2_url'?>" title="<?php printf__'%s latest posts''arras' ), wp_specialcharsget_bloginfo('name'), ) ) ?>" />
    <?php else : ?>
    <link rel="alternate" type="application/rss+xml" href="<?php echo $feed ?>" title="<?php printf__'%s latest posts''arras' ), wp_specialcharsget_bloginfo('name'), ) ) ?>" />
    <?php endif; ?>

    <?php if ( ($comments_feed arras_get_option('comments_feed_url') ) == '' ) : ?>
    <link rel="alternate" type="application/rss+xml" href="<?php bloginfo('comments_rss2_url'?>" title="<?php printf__'%s latest comments''arras' ), wp_specialcharsget_bloginfo('name'), ) ) ?>" />
    <?php else : ?>
    <link rel="alternate" type="application/rss+xml" href="<?php echo $comments_feed ?>" title="<?php printf__'%s latest comments''arras' ), wp_specialcharsget_bloginfo('name'), ) ) ?>" />
    <?php endif; ?>

    <link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />

    <link rel="shortcut icon" href="<?php echo get_template_directory_uri() ?>/images/favicon.ico" />

    <?php
    wp_enqueue_script
    ('jquery'get_template_directory_uri() . '/js/jquery-1.3.2.min.js'null'1.3.2'false);
    wp_enqueue_script('jquery-ui'get_template_directory_uri() . '/js/jquery-ui-1.7.2.min.js''jquery''1.7.2'false); 

    if ( 
    is_home() || is_front_page() ) {
        
    wp_enqueue_script('jquery-cycle'get_template_directory_uri() . '/js/jquery.cycle.min.js''jquery'nulltrue);
    }

    if ( !
    function_exists('pixopoint_menu') ) {
        
    wp_enqueue_script('hoverintent'get_template_directory_uri() . '/js/superfish/hoverIntent.js''jquery'nullfalse);
        
    wp_enqueue_script('superfish'get_template_directory_uri() . '/js/superfish/superfish.js''jquery'nullfalse);
    }

    if ( 
    is_singular() ) {
        
    wp_enqueue_script('comment-reply');
        
    wp_enqueue_script('jquery-validate'get_template_directory_uri() . '/js/jquery.validate.min.js''jquery'nullfalse);
    }

    wp_enqueue_script('jquery-equalheights'get_template_directory_uri() . '/js/jquery.equalheights.min.js''jquery'nullfalse);

    wp_head();
    arras_head();
    ?>
    <script type="text/javascript">
    <?php @include 'js/header.js.php'?>
    </script>

    <!--[if IE 6]>
    <link rel="stylesheet" href="<?php bloginfo('template_url'); ?>/css/ie6.css" type="text/css" media="screen, projector" />
    <script type="text/javascript" src="<?php bloginfo('template_url'); ?>/js/jquery.supersleight.min.js"></script>
    <script type="text/javascript">
        $('#controls').supersleight( {shim: '<?php bloginfo('template_url'?>/images/x.gif'} );
        $('.featured-article').supersleight( {shim: '<?php bloginfo('template_url'?>/images/x.gif'} );
    </script>
    <![endif]-->
    </head>

    <body <?php arras_body_class() ?>>
    <script type="text/javascript">
    //<![CDATA[
    (function(){
    var c = document.body.className;
    c = c.replace(/no-js/, 'js');
    document.body.className = c;
    })();
    //]]>
    </script>
    <?php arras_body() ?>


    <div id="header">
        <div id="branding" class="clearfix">
        <div class="logo clearfix">
            <?php if ( is_home() || is_front_page() ) : ?>
            <h1 class="blog-name"><a href="<?php bloginfo('url'); ?>"><?php bloginfo('name'); ?></a></h1>
            <h2 class="blog-description"><?php bloginfo('description'); ?></h2>
            <?php else: ?>
            <span class="blog-name"><a href="<?php bloginfo('url'); ?>"><?php bloginfo('name'); ?></a></span>
            <span class="blog-description"><?php bloginfo('description'); ?></span>
            <?php endif ?>
        </div>
        <div id="searchbar">
            <?php include (TEMPLATEPATH '/searchform.php'); ?>  
        </div>
        </div><!-- #branding -->
    </div><!-- #header -->

    <?php arras_above_nav() ?>
    <div id="nav">
        <div id="nav-content" class="clearfix">
        <?php if ( function_exists('pixopoint_menu') ): ?>
        <?php pixopoint_menu(); ?>
        <?php else : ?>
            <ul class="sf-menu menu clearfix">
                <li><a href="<?php bloginfo('url'?>"><?php echo arras_get_option('topnav_home'?></a></li>
                <?php 
                
    if (arras_get_option('topnav_display') == 'pages') {
                    
    wp_list_pages('sort_column=menu_order&title_li=');
                } else if (
    arras_get_option('topnav_display') == 'linkcat') {
                    
    wp_list_bookmarks('category='.arras_get_option('topnav_linkcat').'&hierarchical=0&show_private=1&hide_invisible=0&title_li=&categorize=0&orderby=id'); 
                } else {
                    
    wp_list_categories('number=11&hierarchical=1&orderby=id&hide_empty=1&title_li=');    
                }
                
    ?>
            </ul>
        <?php endif ?>
            <ul class="quick-nav clearfix">
                <?php if ($feed == '') : ?>
                    <li><a id="rss" title="<?php printf__'%s RSS Feed''arras' ), wp_specialcharsget_bloginfo('name'), ) ) ?>" href="<?php bloginfo('rss2_url'); ?>"><?php _e('RSS Feed''arras'?></a></li>
                <?php else : ?>
                    <li><a id="rss" title="<?php printf__'%s RSS Feed''arras' ), wp_specialcharsget_bloginfo('name'), ) ) ?>" href="<?php echo $feed?>"><?php _e('RSS Feed''arras'?></a></li>
                <?php endif; ?>
                
                <?php $twitter_username arras_get_option('twitter_username'); ?>
                <?php if ($twitter_username != '') : ?>
                    <li><a id="twitter" title="<?php printf__'%s Twitter''arras' ), wp_specialcharsget_bloginfo('name'), ) ) ?>" href="http://www.twitter.com/<?php echo $twitter_username ?>/"><?php _e('Twitter''arras'?></a></li>
                <?php endif ?>
            </ul>
        </div><!-- #nav-content -->
    </div><!-- #nav -->
    <?php arras_below_nav() ?>

    <div id="wrapper">    
      
        <div id="main" class="clearfix">
        <div id="container" class="clearfix">
    Last edited by rome9t9; 23 September, 2010 at 08:47 AM.

  2. #2
    Aziz's Avatar
    Aziz is offline no investment, no glory
    Join Date
    May 2009
    Location
    IL
    Posts
    736
    Thanks
    588
    Thanked 243 Times in 168 Posts
    Code:
    ?>
            <h1 class="blog-name"><a href="<?php bloginfo('url'); ?>"><?php bloginfo('name'); ?></a></h1>
    to

    Code:
    ?>
            <h2 class="blog-name"><a href="<?php bloginfo('url'); ?>"><?php bloginfo('name'); ?></a></h2>

  3. #3
    rome9t9's Avatar
    rome9t9 is offline No Longer Loves SEO
    Join Date
    Mar 2009
    Location
    If I tell you, I would have to kill you.
    Posts
    614
    Blog Entries
    4
    Thanks
    168
    Thanked 105 Times in 77 Posts
    But then it will make the change in the site title right?? I want the site title to remain in H1 and make the blog post title as H3...

    actually my site is a sales page and the post title is simply a "Hello there"...the targeted keywords in the site title appear in the header and that is why I want it to be in H1..

  4. #4
    Aziz's Avatar
    Aziz is offline no investment, no glory
    Join Date
    May 2009
    Location
    IL
    Posts
    736
    Thanks
    588
    Thanked 243 Times in 168 Posts
    oh well, the post/page titles are located in other files.

  5. #5
    rome9t9's Avatar
    rome9t9 is offline No Longer Loves SEO
    Join Date
    Mar 2009
    Location
    If I tell you, I would have to kill you.
    Posts
    614
    Blog Entries
    4
    Thanks
    168
    Thanked 105 Times in 77 Posts
    I see... below is the page for a single blog post.. there's this one thing called <?php arras_postheader() ?> which makes the post title display in H1 tags...but I don't know where its supposed to be defined in the WP theme files as I am code-handicapped


    single.php
    <?php get_header(); ?>

    <div id="content" class="section">
    <?php arras_above_content() ?>

    <?php
    if ( arras_get_option('single_meta_pos') == 'bottom' ) add_filter('arras_postfooter', 'arras_postmeta');
    else add_filter('arras_postheader', 'arras_postmeta');
    ?>


    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    <?php arras_above_post() ?>
    <div id="post-<?php the_ID() ?>" <?php arras_single_post_class() ?>>

    <?php arras_postheader() ?>

    <div class="entry-content">
    <?php the_content( __('<p>Read the rest of this entry &raquo;</p>', 'arras') ); ?>
    <?php wp_link_pages(array('before' => __('<p><strong>Pages:</strong> ', 'arras'),
    'after' => '</p>', 'next_or_number' => 'number')); ?>
    </div>

    <!-- <?php trackback_rdf() ?> -->
    <?php arras_postfooter() ?>

    <?php if ( arras_get_option('display_author') ) : ?>
    <div class="about-author clearfix">
    <h4><?php _e('About the Author', 'arras') ?></h4>
    <?php echo get_avatar(get_the_author_meta('ID'), 48); ?>
    <?php the_author_meta('description'); ?>
    </div>
    <?php endif; ?>
    </div>

    <?php arras_below_post() ?>
    <a name="comments"></a>
    <?php comments_template('', true); ?>
    <?php arras_below_comments() ?>

    <?php endwhile; else: ?>

    <?php arras_post_notfound() ?>

    <?php endif; ?>

    <?php arras_below_content() ?>
    </div><!-- #content -->

    <?php get_sidebar(); ?>
    <?php get_footer(); ?>

  6. #6
    Aziz's Avatar
    Aziz is offline no investment, no glory
    Join Date
    May 2009
    Location
    IL
    Posts
    736
    Thanks
    588
    Thanked 243 Times in 168 Posts
    remove that and replace with

    Code:
    <h3><?php the_title(); ?></h3>
    you may change the header tag to your liking

  7. Thanked by:

    rome9t9 (23 September, 2010)

  8. #7
    rome9t9's Avatar
    rome9t9 is offline No Longer Loves SEO
    Join Date
    Mar 2009
    Location
    If I tell you, I would have to kill you.
    Posts
    614
    Blog Entries
    4
    Thanks
    168
    Thanked 105 Times in 77 Posts

Similar Threads

  1. Replies: 6
    Last Post: 28 December, 2010, 07:32 AM
  2. [WTT] Proxy List Submission Page / Home Page Trade
    By vectro in forum Links
    Replies: 2
    Last Post: 8 December, 2010, 05:13 AM
  3. SEO of Blog Home Page
    By Andy101 in forum On-Site SEO
    Replies: 3
    Last Post: 7 September, 2010, 04:47 AM
  4. Replies: 0
    Last Post: 29 April, 2010, 12:26 PM
  5. only home page is translating
    By autotech234 in forum Translation Script Support
    Replies: 3
    Last Post: 24 May, 2009, 09:43 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •