I am new to WordPress development and PHP and am developing a child theme based on TwentyTwelve. I have created my own metadata function based on
twentytwelve_entry_meta() that excludes some metadata (author and date) if the post is in a certain category. It took me a lot of time to learn how to do it, but I finally got it done.
While I am very pleased with the results, I would like to take it a little farther. I notice that by default, the categories are listed alphabetically; I would like them to be listed per their Category ID. Reviewing the documentation, I believe that this is a result of
orderby defaulting to
name when I would like it to use
Looking at the
twentytwelve_entry_meta() function, I believe that the categories are produced by
$categories_list = get_the_category_list(__( ', ', 'twentytwelve' ) ); (that's on line 347 of my twentytwelve/functions.php). From looking at http://codex.wordpress.org/Function_Reference/wp_list_categories, it occurred to me that I could use
wp_list_categories() and something like
orderby=id, but I can't make it work.
Does anybody have any ideas? Am I looking in the wrong place? Unfortunately, my site isn't live yet so I cannot provide a link. And although I have created my own metadata function, I believe this question is applicable to the TwentyTwelve theme and its metadata function on its own.
Thank you in advance.