[wp-trac] [WordPress Trac] #18752: Allow category preference in permalinks
WordPress Trac
wp-trac at lists.automattic.com
Thu Sep 22 20:31:53 UTC 2011
#18752: Allow category preference in permalinks
---------------------------+-----------------------------
Reporter: aaroncampbell | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 3.2
Severity: normal | Keywords:
---------------------------+-----------------------------
I know that the general consensus is that a post should be assigned to a
single category and have many tags. However, we ALLOW a user to set as
many categories as they want and I'm constantly facing customers that use
multiple categories and are frustrated that they can't set a "preferred"
category for their permalinks. The category in the permalink is simply
determined by the lowest ID with this code:
{{{
usort($cats, '_usort_terms_by_ID');
}}}
If we add a filter just after that, or better yet change it to a filter
and add the usort USING the filter, then a plugin could use business logic
to decide what category belongs in the permalink instead of being forced
to use one that may make no sense.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/18752>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list