Title: Remove pages from header?
Last modified: August 19, 2016

---

# Remove pages from header?

 *  [joespillers](https://wordpress.org/support/users/joespillers/)
 * (@joespillers)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/remove-pages-from-header-1/)
 * Hey, wondering if anyone could help me. I would like the pages to only be on 
   the sidebar on the right and not on the header under the page title. I have tryed
   to delete some codes from the header.php but keep getting a error. Can anyone
   help? I can move the widgets but they are still there.
 * Here is the the header.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 bloginfo('name'); ?> <?php if ( is_single() ) { ?> &raquo; Blog Archive <?php } ?> <?php wp_title(); ?></title>
   
       <meta name="generator" content="WordPress <?php bloginfo('version'); ?>" /> <!-- leave this for stats -->
       <link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen" />
       <link rel="alternate" type="application/rss+xml" title="<?php bloginfo('name'); ?> RSS Feed" href="<?php bloginfo('rss2_url'); ?>" />
       <link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />
       <!-- <?php bloginfo('stylesheet_directory'); ?>/ -->
       <script language="javascript" type="text/javascript" src="<?php bloginfo('stylesheet_directory'); ?>/js.js"></script>
       <script language="javascript" type="text/javascript">
       	if(f)
       	{
       		write_css('<?php bloginfo('stylesheet_directory'); ?>');
       	}
       </script>
       <?php wp_head(); ?>
       <!--[if IE]>
       <style type="text/css">
       #menu_search_box input.s{
       	width:115px;
       }
       </style>
       <![endif]-->
       </head>
   
       <body>
       <center>
       <div id="page">
   
       <div id="header">
       	<div id="header_top">
       		<div id="header_title">
       			<?php bloginfo('name'); ?> | <span><?php bloginfo('description'); ?></span>
       		</div>
       	</div>
       	<div id="header_end">
       		<div id="menu">
       			<div id="menu_pad">
       				<div id="menu_items">
       					&nbsp;&nbsp;<div><a href="<?php bloginfo('home'); ?>"><span>Home</span></a></div><div>&nbsp;&nbsp;|&nbsp;&nbsp;</div><?php $my_query = new WP_Query('post_type=page&orderby=name&order=ASC'); ?>
   
       <?php while ($my_query->have_posts()) : $my_query->the_post(); 
   
       if( $post->post_parent == 0 )
       {?>
   
       								<div><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></div><div>&nbsp;&nbsp;|&nbsp;&nbsp;</div>
   
       <?php } endwhile;
       ?>
       				</div>
       				<div id="menu_search_box">
       					<form method="get" id="searchform" style="display:inline;" action="<?php bloginfo('home'); ?>/">
       					<span>Search:&nbsp;</span>
       					<input type="text" class="s" value="<?php the_search_query(); ?>" name="s" id="s" />&nbsp;
       					<input type="image" src="<?php bloginfo('stylesheet_directory'); ?>/images/go.gif" value="Submit" class="sub"   />
       					</form>
       				</div>
       			</div>
       		</div>
       	</div>
       </div>
   
       <div id="blog">
       	<div id="blog_left">
       		<?php get_sidebar(); ?>
       	</div>
       	<div id="blog_center">
       ```
   
 * Oh and im using the transblack 1.0 theme.

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

 *  [esmi](https://wordpress.org/support/users/esmi/)
 * (@esmi)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/remove-pages-from-header-1/#post-1355387)
 * Please don’t post huge chunks of code here. For larger blocks of code, use the
   [WordPress pastebin](http://wordpress.pastebin.ca/) and post the pastebin url
   here. It makes life easier for everyone.
 * Try removing:
 *     ```
       <div>&nbsp;&nbsp;|&nbsp;&nbsp;</div><?php $my_query = new WP_Query('post_type=page&orderby=name&order=ASC'); ?>
       <?php while ($my_query->have_posts()) : $my_query->the_post();
       if( $post->post_parent == 0 ) {?>
       	<div><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></div><div>&nbsp;&nbsp;|&nbsp;&nbsp;</div>
       	<?php }
       endwhile;?>
       </div>
       ```
   
 *  Thread Starter [joespillers](https://wordpress.org/support/users/joespillers/)
 * (@joespillers)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/remove-pages-from-header-1/#post-1355422)
 * Ok sorry.
 * That removed the pages, however made the rest of the page mess up a bit :S
 * any other options? x
 *  [esmi](https://wordpress.org/support/users/esmi/)
 * (@esmi)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/remove-pages-from-header-1/#post-1355425)
 * You’ll probably have to adjust the CSS in the theme’s stylesheet now.
 *  Thread Starter [joespillers](https://wordpress.org/support/users/joespillers/)
 * (@joespillers)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/remove-pages-from-header-1/#post-1355428)
 * I see, well there is 2 CSS files in the theme,
 * styleie.css which contains:
 *     ```
       #blog_right #sidebar2{
       	padding-left:15px;
       }
   
       #blog_center #blog_comm{
       	margin-left:15px;
       }
       ```
   
 * and style .css which contains:
 * [here](http://wordpress.pastebin.ca/1762258)
 * Thanks
 *  [esmi](https://wordpress.org/support/users/esmi/)
 * (@esmi)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/remove-pages-from-header-1/#post-1355626)
 * Make your changes to style.css.

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

The topic ‘Remove pages from header?’ is closed to new replies.

## Tags

 * [header](https://wordpress.org/support/topic-tag/header/)
 * [pages](https://wordpress.org/support/topic-tag/pages/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 5 replies
 * 2 participants
 * Last reply from: [esmi](https://wordpress.org/support/users/esmi/)
 * Last activity: [16 years, 4 months ago](https://wordpress.org/support/topic/remove-pages-from-header-1/#post-1355626)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
