WordPress.org

Ready to get started?Download WordPress

Forums

Posts in a Specific Category Having the_category Return Wrong Cat in Single Post (2 posts)

  1. zakkath
    Member
    Posted 1 year ago #

    I do not have a live version of this site to show, but what is happening is on the front page, the categories are being displayed correctly by the following code:

    <footer class="postfooter">
       <h5 class="postcategory">Filed in <?php the_category(', ') ?></h5>
    </footer>

    However when I view these as single posts they that same code will return the result completely different. The posts are assigned the Category ID of 4 and the value being returned in single post is the name of Category ID 3.

    I happen to be running the WordPress SEO plug-in and in the breadcrumbs it generates, the Category 4 is being correctly displayed.

    This only happens on posts assigned Category 4. Posts assigned in any other category are working just fine. I shut down all running plug-ins and the error still occurred.

    Any help would be greatly appreciated.

  2. zakkath
    Member
    Posted 1 year ago #

    Still having this problem....

Topic Closed

This topic has been closed to new replies.

About this Topic