• OK, this has been an ongoing problem since I’ve converted an XHTML/CSS template into WordPress compatibility. Because on another template when I click on a category, it will show ALL the posts listed under that category.

    However, the current template I have shows only ONE post that is listed under that category. What do I need to do to fix this?

Viewing 8 replies - 1 through 8 (of 8 total)
  • Can we see the code you are suing to call the categories?

    You need to give more details for people to sort this problme.
    But then in the template design check the category post function and see the loop size! It might execute just once!

    Check that 🙂

    Thread Starter Aimee

    (@aimeeish)

    Example: http://www.emmafrostfiles.com/category/previews/

    Only shows one post when there are at least over 20 entries categorized under previews. The next post and previous links won’t show either!

    Here’s the loop I have in the category.php:
    <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
    html post stuff here
    <?php endwhile; else: ?><?php endif; ?>

    Looks to me like it only executes once. Suspiciously you only display one post on your homepage as well. Maybe you are reusing the same post include for both pages? I would echo out some text into that loop to see if it is even executing and if you are editing the correct file.

    Thread Starter Aimee

    (@aimeeish)

    Well…how do I do that?

    could you post the content of your category.php file ?

    Thread Starter Aimee

    (@aimeeish)

    Yes!

    <?php
    /*
    Template Name: Categories Page
    */
    ?>
    <?php get_header(); ?>
    <div id="content_wrapper">
    	<div class="main_content">
    <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
    <div class="main_box">
    		<div class="main_box_inside">
    			<div class="main_box_content">
    				<h2><span><img src="http://www.emmafrostfiles.com/images/newspaper.png" title="<?php the_title() ?>" alt="<?php the_title() ?>"/> Latest News Item</span></h2>
    				<div class="real_content">
    				<h3><?php the_title() ?></h3>
    				<div class="date"><?php the_date() ?> at <?php the_time() ?></div>
    				<?php the_content('<img src="http://www.emmafrostfiles.com/wp-content/themes/eff_v3/images/read_more_button.gif" alt="Read More" title="Read More"/>'); ?><br />
    <div class="hr"></div>
    <small>Posted in <?php the_category(',', 'parents' ); ?> by <?php the_author_nickname(); ?> | <a href="<?php the_permalink(); ?>#respond" title="respond"><img src="http://www.emmafrostfiles.com/images/comment_add.png" alt="respond"/></a> | <img src="http://www.emmafrostfiles.com/images/comments.png" alt="comments"/> <a href="<?php comments_link(); ?>"><?php comments_number('no comments','1 comment','% comments'); ?></a> | <img src="http://www.emmafrostfiles.com/images/page_white_link.png" alt=""/> <a href="<?php the_permalink(); ?>" title="Permalink">Permalink</a></small>
    <?php previous_posts_link('Previous', '0'); ?>  <?php next_posts_link('Next', '0)'); ?>
    				</div><!--end of real_content-->
    			</div><!--end of main_box_content-->
    		</div><!--end of main_box_inside-->
    		</div><!--end of main_box-->
    	<?php endwhile; else: ?><?php endif; ?>
    </div><!--end of main_content-->
    	<?php get_sidebar(); ?>
    	<?php get_footer(); ?>
    Thread Starter Aimee

    (@aimeeish)

    What the heck…for months I’ve been trying to get help with this. And people always run away!!

    Aghhhh.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘What is wrong with my categories? It only shows one entry!’ is closed to new replies.