1
I’m developing a theme for Wordpress
my menu is generated as follows in header.php
<li><a href="<?php echo get_option('home');?>">Início</a></li>
<?php wp_list_categories('title_li=&orderby=id'); ?>
<?php wp_list_pages('title_li=&order=id'); ?>
The problem is that when I access a category when trying to show posts it returns all posts and not those referring to category.
Category.php
<?php if ( have_posts() ) : ?>
<?php while ( have_posts() ) : the_post(); ?>
<?php the_title(); ?>
<?php endwhile; ?>
<?php endif; ?>
the problem is that it’s not just a category!
– wwwjsw
Ever tried using is_category()? Then you pass your category, do an if, don’t know how you want to do it.
– Vanderson Ramos
Try to give more explanations about your solution, so it will also be useful to future visitors
– Ricardo