jjleroux
Forum Replies Created
Viewing 1 replies (of 1 total)
-
Forum: Fixing WordPress
In reply to: Category posts don’t show like frontpagePlease help me ?? I am having the same problem, I’ve managed to duplicate index.php to category.php which has made my category pages exactly the same as my front page (which I use for latest posts), but how do I keep the category pages still listing posts for that category? Basically I just want to same layout as the front page for my category page.
Below is my category.php code, which bit to I need to change or add to make the posts just from the relevant category?
<?php get_header(); ?> <?php $my_query = new WP_Query('showposts=1'); ?> <?php while ($my_query->have_posts()) : $my_query->the_post(); ?> <div class="top_post" id="post-<?php the_ID(); ?>"> <div class="post_title"> <h2> <div class="headline"> LATEST BLOGS </div> <div class="headline_date"> <?php the_time('F jS, Y') ?> </div> </h2> </div> <div class="top_entry"> <div class="top_titles"> <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a> </div> <?php the_content('Read the rest of this entry »'); ?> </div> <div class="post_bottom"> <div class="post_cat"> </div> </div> </div> <?php endwhile; ?> <?php rewind_posts(); ?> <div id="about_box2"> <img src="https://pugwashmagazine.com/wp-content/uploads/jen.jpg" width="70"/> <h3> WRITE FOR US </h3> <?php include (TEMPLATEPATH . '/about2.txt'); ?> </div> <div id="content"> <?php query_posts('showposts=10&offset=1'); ?> <?php if (have_posts()) : ?> <?php while (have_posts()) : the_post(); ?> <div class="mag_posts" id="post-<?php the_ID(); ?>"> <div class="top_mag_posts"> <div class="bottom_mag_posts"> <h2><?php the_category(', ') ?></h2> <div class="mag_posts_entry"> <div class="top_mag_titles"> <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a> </div> <?php the_content(); ?> </div> <div class="mag_posts_meta"> <div class="meta_date"><?php the_time('j') ?> <?php the_time('F') ?> <?php the_time('Y') ?></div> <div class="meta_comments"> <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">Read More >></a></div> </div> </div></div></div> <?php endwhile; ?> <?php endif; ?> </div> <?php include (TEMPLATEPATH . '/rightads.php'); ?> <?php get_sidebar(); ?> <div class="clear"></div> <?php get_footer(); ?>
Viewing 1 replies (of 1 total)