WordPress.org

Ready to get started?Download WordPress

Forums

Loading wrong category content! (5 posts)

  1. nathanairplane
    Member
    Posted 5 years ago #

    I'm working on setting up a blog with a custom theme, and strange things are happening in the categories. When I go to a given category archive page, WordPress seems confused about which category it's on. The title (what's in <title>) is the name of the correct category. But the title of the category on the page itself is wrong; it gives the name for a different category. The list of posts, also, are for the wrong category. The category description, however, comes out correct!

    Here, for instance, is the code in the template for the title and the description. What it produces, for some reason, is the wrong title and the right description:

    if (is_category()) { ?>
    		<h2><?php single_cat_title(); ?></h2>
    		<div class="excerpt"><?php echo category_description(); ?></div>

    On every category page, the wrong elements point to the same category, id=3, each time.

    The installation is currently under .htaccess password protection. Could this have anything to do with it?

  2. nathanairplane
    Member
    Posted 5 years ago #

    please help!

  3. nathanairplane
    Member
    Posted 5 years ago #

    nobody has any ideas?

  4. nathanairplane
    Member
    Posted 5 years ago #

    I've just noticed another problem! When I run test searches in the WordPress search field, the only results I get, no matter what I search for, are those same posts from category id=3. This is so weird.

  5. whooami
    Member
    Posted 5 years ago #

    and what happens when the default theme is used?

    start by narrowing down the potential causes.

    this is simple to troubleshoot, whats the problem, have you done that? still occurring with the default theme? disable plugins? what then?

Topic Closed

This topic has been closed to new replies.

About this Topic