#6523 closed defect (bug) (invalid)
get_terms() bug
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 2.5 |
Component: | General | Keywords: | |
Focuses: | Cc: |
Description
This plugin:
http://wordpress.org/extend/plugins/my-category-order/installation/
requires that one change the taxonomy.php file...
because there's a missing case in get_terms()
Change History (6)
#2
@
17 years ago
Denis-de-Bernardy, are you able to attach patches? Please see http://codex.wordpress.org/Reporting_Bugs#Patching_Bugs
#3
@
17 years ago
I'm afraid not... I run a customized version of WP and I've set up a dedicated svn for it. The patches I can generate won't work any more with your svn than the ones you're generating on mine. In the future, I'll try to set it up with WP as an external reference. Until then, I'm stuck with reporting bugs and findings. ;-)
Speaking of which, the above fix is not the only necessary change. The My Category Order plugin doesn't work as documented. There's a db query beneath the above code in get_terms() that also needs an extra table to avoid DB errors. And then, you get duplicate results all over the place.
I stopped looking into the issue upon getting the latter, as I had more important stuff to care about at the moment.
Still, the WP DB schema has a term_order field that is just asking to become useful. Maybe the plugin's developer will come up with the fix?
D.
#4
@
17 years ago
Denis-de-Bernardy, surely it's trivial to maintain a clean WordPress check out to create your patches verses. The core developers being able to see the colorized diffs makes it more likely that your fixes get incorporated quickly.
#5
@
17 years ago
- Resolution set to invalid
- Severity changed from major to normal
- Status changed from new to closed
term_order is in the term_relationships table. Adding it to a possible order field for get_terms doesn't make any sense, because get_terms gets terms by taxonomy, not by a relationship with a post. The SELECT statement in get_terms does not even include a JOIN to the term_relationships table or a reference to it as "tr".
Marking this as invalid, because it makes no sense.
it should go like this:
(the term_order case is missing)