Support » Fixing WordPress » Get rid of h1 on index page

  • Resolved robertallen


    Hi all,

    How do I get rid of the H1 on index.php page? I don’t even have one…but I’m guessing it’s somewhere in the engine. I tried hiding it in the CSS but it hides the other H1’s. I only want H1 off the index.php page.

    The problem is it’s interfereing with my navigation…

Viewing 5 replies - 1 through 5 (of 5 total)
  • noahjonah


    Delete the <h1> tag



    Yep, normally that would work, but the strangest thing is it’s not there.

    This is what I have…no h1 tags…

      if (have_posts()): ?>
      <ol id="posts"><?php
        while (have_posts()) : the_post(); ?>
        <li class="postWrapper" id="post-<?php the_ID(); ?>">
          <h2 class="postTitle"><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
          <small><?php the_date(); ?> by <?php the_author(); ?></small>
          <div class="post"><?php the_content(__('(more...)')); ?></div>
          <p class="postMeta">Category: <?php the_category(', ') . " " . the_tags(__('Tags: '), ', ', ' | ') . comments_popup_link(__('Comments (0)'), __('Comments (1)'), __('Comments (%)')) . edit_post_link(__('Edit'), ' | '); ?></p>
          <hr class="noCss" />
        <?php comments_template(); // Get wp-comments.php template ?>
        <?php endwhile; ?>
    <?php else: ?>
      <p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
      <?php if (will_paginate()): ?>
        <ul id="pagination">
          <li class="previous"><?php posts_nav_link('','','&laquo; Previous Entries') ?></li>
          <li class="future"><?php posts_nav_link('','Next Entries &raquo;','') ?></li>
      <?php endif; ?>



    get_header() gets the header.php file — and you do have an h1 tag there:

    <div id="navcontainer">
    	<h1><a href=''>AweStar Minitries</a> <span></span></h1>

    Why are you trying to remove it?

    Or is that the one that is “being interfered with?” How so?



    That’s so odd. Well, actually, I just want the h1 tags as titles of the pages and the blog posts, not on the index page.

    I still can’t find it in the header.php. This is the wierdest thing. Is there another header.php with functions?

    Another reason is it’s interfereing with the Navigation bar. I wouldn’t mind keeping it if I could just find it to stylize it with a class selector.

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">
    <html xmlns="" <?php language_attributes(); ?>>
    <head profile="">
    	<meta http-equiv="Content-Type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" />
    	<title><?php if(is_home()) bloginfo('name'); else wp_title(''); ?></title>
    	<style type="text/css" media="screen">
    		@import url( <?php bloginfo('stylesheet_url'); ?> );
        <link rel="stylesheet" type="text/css" href="" />
        <link rel="shortcut icon" href="" />
    	<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="<?php bloginfo('rss2_url'); ?>" />
    	<link rel="alternate" type="text/xml" title="RSS .92" href="<?php bloginfo('rss_url'); ?>" />
    	<link rel="alternate" type="application/atom+xml" title="Atom 1.0" href="<?php bloginfo('atom_url'); ?>" />
    	<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />
    <div id="container">
    <div id="header">
    	<div class="logo">
        <a href=""><img src="" alt="Awe Star Ministries" border="0" /></a>
    	<div id="navcontainer">
            // see this theme's functions.php
            print do_heading();
            print naked_nav($post);
            <div class="social">
            <img src="" alt="Facebook" border="0" />
            <img src="" alt="Twitter" border="0" />


    Hmmm, I guess what I can do is just hide it in the CSS, and unhide the h1’s that I want.

    Thank you guys so much for your answers. Such a crazy thing of the phantom h1 tag. That’s what I get for using a blank wordpress theme sometimes, but it’s a lot easier than configuring something from a blank slate sometimes.

    Appreciate it all!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Get rid of h1 on index page’ is closed to new replies.