WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] wp_list_cats - force different sort order? (4 posts)

  1. bwooster47
    Member
    Posted 8 years ago #

    wp_list_cats allows the sorting to occur by either the ID, or the name.

    Is there any way to force a specific order for the categories other than name?

    ID is assigned automatically by the system, did not see any way to change it (without mucking around the database).

    What I would like is a "SortID" field for each category, that I could edit as needed, and use that in the wp_list_cats as sort_column.

    Is there any other currently available workaround to do this?

  2. tsguitar
    Member
    Posted 8 years ago #

    Give this a shot:
    http://pericat.ca/unlock/2005/02/20/explicit-category-sort-plugin/

    Or this (bottom of the page, "Category Order 1.9.4"):
    http://www.coppit.org/code/

  3. bwooster47
    Member
    Posted 8 years ago #

    Thanks!

    Just installed Category Order 1.9.4 mentioned above, and works just fine.

    Did run into some problem with "hierarchical" option for wp_list_cats, seems to be working strangely, but don't have time to debug that, figured out a combination that works, so all fine for now!

    I would recommnend that plugin as a great thing to add to the standard WordPress kit - it is essential!

  4. bwooster47
    Member
    Posted 8 years ago #

    Found a bug in Category Order 1.94 plugin.

    It strips out all the class definitions from the original list of categories, therefore:

    <li class="current-cat">
    ends up without the current-cat class and just becomes
    <li>
    which is something I was depending on... will send this bug report to the author, in case this is fixable...

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.