Support » Themes and Templates » Page displays post instead of page content

  • Resolved brucehere365


    I currently am having a strange problem where I have basic theme built.
    All posts are displaying fin and the homepage with a list of posts.
    No problems there.
    My current page.php looks like the following:

    <?php get_header(); ?>
    <div id="content">
    			  <div id="entry">
        <div id="post-content">
        <h1><?php the_title(); ?>.</h1>
    	<?php the_content(); ?>
        <!-- end #entry --></div>
             <?php get_sidebar(); ?>
             <?php get_footer(); ?>

    I have an index.php file which has the loop in it (I think)

    <?php if (have_posts()) : ?>
                  <?php while (have_posts()) : the_post(); ?>
        <h1><div class="title-category"><a class="bolder" href="<?php the_permalink(); ?>" ><?php the_title(); ?>.&nbsp;</a> <a class="semibold"><?php the_category(); ?></a></div>
         <div class="date"><?php the_time('m.d.Y'); ?></div></h1>
        <div id="post-content">
        <?php the_content(); ?>
        <!-- bottom share area -->
        <div class="title-category"><iframe src="<?php the_permalink() ?>&show_faces=false&colorscheme=light"
            scrolling="no" frameborder="0"
            style="border:none; width:400px; height:30px"></iframe>  <a class="semibold"></a></div>
         <div class="social">
    <div id="custom-tweet-button">
          <a href="" class="twitter-share-button" data-url="<?php the_permalink() ?>" data-count="none">Tweet</a><script type="text/javascript" src="//"></script>
    </a><div id="comm"><a class="bolder" href="<?php the_permalink(); ?>#comments" >Comment</a><?php comments_number('(0)','(1)','(%)'); ?></div></div>
         <br /><br />
     <?php //echo do_shortcode("[fb_like]"); ?>
        <div class="hr"></div>
        <!-- end #entry --></div>
        <?php endwhile; ?>
       	 <?php endif; ?>

    I am not really sure where it’s going wrong? Some help would be appreciated.
    Site is
    and more specifically an example page is

Viewing 2 replies - 1 through 2 (of 2 total)
  • Moderator Jose Castaneda



    Um, you may want to check because I keep getting an error on my end. Tells me: Parse error: syntax error, unexpected $end in /home/huemanwr/public_html/alm/wp-content/themes/alm_theme/header.php on line 173

    Look like i was missing
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    from the top of the page.php file 😉

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Page displays post instead of page content’ is closed to new replies.