WordPress.org

Support

Support » Themes and Templates » [Resolved] Displaying categories alphabetically

[Resolved] Displaying categories alphabetically

  • I’m developing a wordpress site (blog.thirstforfiction.com), and one of the essential things is that I can display the subcategories of a category alphabetically. Currently, I can display the subcategories using this code:

    <?php if (is_category()) {
      $this_category = get_category($cat);
      if (get_category_children($this_category->cat_ID) != "") {
        echo "<h2>Subcategories</h2>";
        echo "<ul>";
        wp_list_categories('orderby=id&show_count=0&title_li=
    &use_desc_for_title=1&child_of='.$this_category->cat_ID);
        echo "</ul>";
      }
    }
    ?>

    But I don’t know how to display the results alphabetically. I’ve tried various tutorials, but my PHP knowledge is incredibly shallow.

    Anyone know how to edit the above code to display results alphabetically?

    PS: It’s specifically http://blog.thirstforfiction.com/authors that I want this for.

    Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Resolved] Displaying categories alphabetically’ is closed to new replies.