#43002 closed defect (bug) (invalid)
Can't order tag cloud by tag_cloud_sort filter
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Priority: | normal | |
| Severity: | normal | Version: | |
| Component: | Taxonomy | Keywords: | reporter-feedback |
| Focuses: | Cc: |
Description
I can't re-order tags by tag_cloud_sort filter, because the order is same with id order.
Change History (5)
#2
in reply to:
↑ 1
@
8 years ago
Replying to birgire:
@yuetyeelo2855 Welcome to WordPress trac.
Can you please extend the bug report,
e.g. with an example so it can easily be reproduced and verified.
Thanks.
It is no common case, If the user create tag like
tag1[id=1], tag2[id=2], tag3[id=3]
want the tage order like
tag1[id=1, post_count=5], tag2[id=2, post_count=20], tag3[id=3, post_count=10]
so using WordPress filter tag_cloud_sort to order by extra column tag_order
tag1[id=1, tag_order=1], tag2[id=2, tag_order=2], tag3[id=3, tag_order=3]
but the order will not work. it will follow the post count.
ASC:
tag1[id=1, post_count=5], tag3[id=3, post_count=10], tag2[id=2, post_count=20]
DESC:
tag2[id=2, post_count=20], tag1[id=1, post_count=5], tag3[id=3, post_count=10]
Can we re-order the order of logic, make the default order go first, than exec the filter tag_cloud_sort.
the position wp-includes/category-template.php line no. 821-844
#4
@
5 months ago
- Resolution set to invalid
- Status changed from new to closed
Hi @yuetyeelo2855,
From the report it's not clear if this is a bug, implementation error, or a change request. Since it has been 7 years and no action has been taken, and we don't have other reports/requests for this, I'm going to close this to help clean up Trac.
If this is still an issue, feel free to reopen. In that case, it would help to clarify the issue here, provide info about your site environment, and the code you're using to filter the sort order.
@yuetyeelo2855 Welcome to WordPress trac.
Can you please extend the bug report,
e.g. with an example so it can easily be reproduced and verified.
Thanks.