[wp-testers] get_category Ordering Weirdness?
Jennifer Hodgdon
yahgrp at poplarware.com
Thu Dec 20 16:00:13 GMT 2007
Looking at the function, it looks like hierarchical=true is the
default, which is probably screwing up the order. Try adding
hierarchical=0 to the arg list and see if that helps.
--Jennifer
Tom Belknap wrote:
> Hello all!
>
> I'm using WPMU 1.3, which is the 2.3.1 codebase, and experiencing some problems with the get_categories function and what appears to be an ordering problem. If I choose to order by ID or by name, ascending or descending, the results are different in each case, which suggests that the function must at least be *trying* to order the list. However, the list never comes out right.
>
> Here is my code:
> <?php
> require('./wp-blog-header.php');
>
> switch_to_blog(6);
> $categories = get_categories('orderby=ID&order=desc');
--
Jennifer Hodgdon
Poplar ProductivityWare * www.poplarware.com
Web Databases/Scripts * Modeling/Analysis/Palm OS Software
More information about the wp-testers
mailing list