Support » Fixing WordPress » Category pages showing ALL blog entries

Viewing 15 replies - 1 through 15 (of 22 total)
  • Could you paste here the loop you use in category.php ?


    Ok I feel really dumb. Where can I find this? I looked and am not seeing it anywhere…is that my problem? I’m still fairly new at WordPress, so please excuse my stupidity.. :-/

    Ok… Did tou make any theme customisation or you are using a theme out-of-the-box from wordpress (default or classic…) ?

    Could you tell us the theme you use… ?

    But, to answer your question, “the loop” is a part of the .php files in wordpress. Searh the “codex” about it… You will find plenty of information…

    The problem is surely the loop in the “category.php” file…

    Browse to your wordpress folder installation.

    Go to wp-content/themes/the_theme_you_use

    You will find there a file named category.php

    What is written there ?

    Paste it here between code mark.


    You will find there a file named category.php

    Not necessairly… Most themes do NOT have that template file. See Template_Hierarchy.

    And do not post long code here: it is diffcult to read. Use something like

    Right. This is why I asked him what theme he is using…



    I am using Sodelicious Black theme (

    I think the problem is that I don’t have a category.php file, at least there’s not one listed in my theme folder. How would I go about creating one? I tried to do a search, but didn’t find anything that told me how to create a new one.

    Does this theme that I chose just suck??

    Thanks for your help!

    I found the Category Template page which might help, but if there’s an easy answer for what to put in the category.php file, I’d appreciate it. Thanks again! 🙂

    As Moshu wrote in this thread, you don’t necessairly need a category.php file…

    With the “template hierarchy” of WordPress, if you dont have a category.php page, index.php will be used instead..

    So, your next step is to show us the content of the index.php, wich is used instead of category.php, in your theme…

    Also, just to be sure, try to switch theme… Choose the “default” one… Does it help ? If so, then your problem is theme relative…


    Ok… I think I found your problem. The theme “Sodelicious Black” contains an error…

    In index.php, at line 52, you will fnd :

    <?php query_posts('showposts=5'); ?>

    The author used this query to display last 5 posts… But if you have a query_posts on a page, it will bypass the normal loop… So it sucks… 😉

    Try to switch theme to confirm, but I’m pretty sure that it’s the problem…


    Yikes, yeah it works fine when I switch themes. Is there any harm in taking that line out, do you think?


    Try this solution :

    Download this file :

    Decompress it (it’s a .rar)

    upload the category.php file it contains to your theme directory ( wp-content/themes/sodelicious-black-10 )

    Tell me if it works…


    I added that and it still shows all posts instead of just that category’s posts. 🙁

    Well… 🙁

    🙂 Wrong solution… Sorry. Delete the file from your theme directory and let’s find something else…

    It’s weird, cause I tried your theme and it works on my side… Choosing a category only displays the post from this category with the theme…

    But we’re still sure that your problem is relative to the theme you use, cause when you switch theme, it works well…


    I know you told us that you are still fairly new at WordPress, but did you made some customisations of any kind? Did you change any code from the theme template (exept design modification such as pictures and CSS) ?


    I did make a few changes in the index.php file. I’m not new to coding, just to WordPress (though I’m not super familiar with PHP). I really just moved some code around (like the footer of each post was at the top before and I moved it to the bottom) and changed the way the date appears. Then I just added images and changed some of the CSS. Other than that I haven’t done too much…definitely haven’t added any code or really changed any of the php stuff.

    I double checked the Default WordPress theme and the Classic theme and both do the same thing.

    I noticed that I don’t have the archive.php file either so according to the hierarchy it’s defaulting to the index.php. Would you like to take a look at my index.php file? I can zip it and post a link if you’d like.

    Thanks again for your help, I really do appreciate it!


    Sure, zip it somewhere and I’ll have a look.


Viewing 15 replies - 1 through 15 (of 22 total)
  • The topic ‘Category pages showing ALL blog entries’ is closed to new replies.