Title: Page.php Problem
Last modified: August 18, 2016

---

# Page.php Problem

 *  Resolved [shanesque](https://wordpress.org/support/users/shanesque/)
 * (@shanesque)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/)
 * I’m currently working on my page.php for my own theme. I want my pages to have
   comment forms. The problem is that when I add <?php comments_template(); ?> to
   the page. The results is this [(problem)](http://i8.photobucket.com/albums/a40/shanesque/wordpress/testpage.jpg).
   It appears that nothing is wrong but I have a plugin which tells how many comments
   each entry has. For this particular page there are NO comments but the comment
   number for my blog is showing up in the page template. This is my page template:
   <br>
    <?php require_once(“/home/intricat/public_html/wp-blog-header.php”);?><?
   php get_header(); ?> <div id=”content” class=”narrowcolumn”>
 *  <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    <div class=”
   post” id=”post-<?php the_ID(); ?>”> <div class=”entrytext”> <?php the_content(‘
   <p class=”serif”>Read the rest of this page »</p>’); ?> <?php comments_template();?
   > <?php link_pages(‘<p>**Pages:** ‘, ‘</p>’, ‘number’); ?>
 *  </div>
    </div> <?php endwhile; endif; ?> <?php edit_post_link(‘Edit this entry.’,‘
   <p>’, ‘</p>’); ?> </div> <?php get_sidebar(); ?><?php get_footer(); ?><br> How
   can I get my page template to stop displaying comment counts from my blog?

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

 *  [vkaryl](https://wordpress.org/support/users/vkaryl/)
 * (@vkaryl)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502479)
 * You need to edit that code section, use backticks to surround the code (the oddball
   symbol under the tilde – the other oddball symbol – on the key to the left of
   the numeral one key on English keyboards) – repaste the entire code section using
   the backticks this time, or paste it to [http://wordpress.pastebin.ca](http://wordpress.pastebin.ca),
   and post the link back here.
 *  Thread Starter [shanesque](https://wordpress.org/support/users/shanesque/)
 * (@shanesque)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502482)
 * I don’t understand what you mean…
 *  Thread Starter [shanesque](https://wordpress.org/support/users/shanesque/)
 * (@shanesque)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502483)
 * `<?php get_header(); ?>
    <?php if (have_posts()) : while (have_posts()) : the_post();?
   > <div class="storytitle"><b><?php the_title(); ?></b> <?php the_time(' F jS 
   Y ',true); ?></div> <div class="storyinfo"><img src="/wp-content/themes/frequencies/
   images/book.gif" align="middle" hspace="2"> <?php _e('Filed under'); ?>  <?php
   the_category(', ') ?> <img src="/wp-content/themes/frequencies/images/clock.gif"
   align="middle" hspace="2"> <?php the_time() ?> <img src="/wp-content/themes/frequencies/
   images/pencil.gif" align="middle" hspace="2"> &nbsp; <b><?php echo(str_word_count(
   get_the_content())); ?></b> Words in Post</div> <div class="post"> <?php wp_link_pages();?
   > <?php the_content(__('Read the rest of this entry')); ?> <?php comments_template();?
   > </div>  <?php endwhile; else : ?></div> <h2><?php _e('Not Found'); ?></h2> 
   <?php _e('Sorry, but the page you requested cannot be found.'); ?> <h3><?php 
   _e('Search'); ?></h3> <?php include (TEMPLATEPATH . '/searchform.php'); ?> <?
   php endif; ?> <?php get_sidebar(); ?><?php get_footer(); ?>
 * Do you mean like this?
 *  [vkaryl](https://wordpress.org/support/users/vkaryl/)
 * (@vkaryl)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502484)
 * Just put it at pastebin please (link above) and then put the link here.
 *  [moshu](https://wordpress.org/support/users/moshu/)
 * (@moshu)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502485)
 * [just a technical note: if there is a blank line in the code in between the backticks`–
   that breaks the “magic” 😉 ]
 *  Thread Starter [shanesque](https://wordpress.org/support/users/shanesque/)
 * (@shanesque)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502486)
 * [http://wordpress.pastebin.ca/314833](http://wordpress.pastebin.ca/314833)
 *  [moshu](https://wordpress.org/support/users/moshu/)
 * (@moshu)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502487)
 * And here is what you need for a Page template inside the WP theme folder:
    [http://codex.wordpress.org/Pages#Page_Templates](http://codex.wordpress.org/Pages#Page_Templates)
 * (it seems your “template” is outside of WP since it has to have this:
    `require_once("/
   home/intricat/public_html/wp-blog-header.php` – in this case I’d avoid calling
   it page.php – that filename is on the list of special template files)
 *  [vkaryl](https://wordpress.org/support/users/vkaryl/)
 * (@vkaryl)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502488)
 * Yes, like that. And thanks for the pastebin link too (which keeps the indents
   in the formatting – easier for me to read that way).
 * I don’t see anything in there that would cause what your screenshot does. However,
   trying to troubleshoot with a screenie is useless. Could you provide a real link
   to the problem?
 * [Ah. Missed that, mosh’!]
 *  Thread Starter [shanesque](https://wordpress.org/support/users/shanesque/)
 * (@shanesque)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502494)
 * [http://www.intricate-life.com/?page_id=9](http://www.intricate-life.com/?page_id=9)
 * Even using that template page WP tut, I’m still getting the same results. I took
   the require once bit out and put just the header include. Still the same results.
 *  Thread Starter [shanesque](https://wordpress.org/support/users/shanesque/)
 * (@shanesque)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502496)
 * [http://wordpress.pastebin.ca/314861](http://wordpress.pastebin.ca/314861)
 * That’s what my template page looks like.
 * I’m thinking maybe something is wrong with my comments template which is causing
   the problem but I’m not really sure.
 *  [moshu](https://wordpress.org/support/users/moshu/)
 * (@moshu)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502501)
 * That’s not the template – it is the plugin as you said in your OP (original post).
   Don’t use the plugin if it conflicts with your Page design ideas 🙂
 *  Thread Starter [shanesque](https://wordpress.org/support/users/shanesque/)
 * (@shanesque)
 * [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502503)
 * Yeah you’re right, both of those plugins were conflicting with my theme, I solved
   the problem now, thanks to the both of you.

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

The topic ‘Page.php Problem’ is closed to new replies.

## Tags

 * [page.php](https://wordpress.org/support/topic-tag/page-php/)
 * [problem](https://wordpress.org/support/topic-tag/problem/)

 * 12 replies
 * 3 participants
 * Last reply from: [shanesque](https://wordpress.org/support/users/shanesque/)
 * Last activity: [19 years, 5 months ago](https://wordpress.org/support/topic/pagephp-problem/#post-502503)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
