Plugins & Hacks

How can I change the order of my categories?

Scenario:
"I want my categories to appear in a particular order in my categories list, but Nucleus always puts them in alphanumeric order! How can I 'trick' Nucleus into doing what I want?"

Solution:
You can use a little bit of html to hide your trick from displaying in browsers and force Nucleus to order your categories in a particular way.

When creating your categories, all you need to do is prefix each category as follows:

<!--XX-->Category name

where XX is the numeric order you want your categories to appear in. So for example, prefixing a category with this:

<!--01-->My first category

will cause the category "My first category" to display at the very top of your categories list.

You can still use this trick by renaming your existing categories.

Original forum thread (thanks, Andy!):
http://forum.nucleuscms.org/viewtopic.php?t=8160

section: Plugins & Hacks | submitted by Leng on 2006.Aug.12 | 2382 views

item rate
Total votes: 8 - Rating: 8.88

Please tell us how useful this answer was to you (0 = useless, 10 = very very helpful):

10