#14073 closed defect (bug) (invalid)
Custom Taxonomies - Post Count wrong
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 3.0 |
Component: | Taxonomy | Keywords: | reporter-feedback dev-feedback |
Focuses: | Cc: |
Description
I've just set up some custom taxonomies on our blog.
Basically they are just some basic custom tag-clouds for a few different subjects
But i've come across what appears to be a weird bug
After creating my custom taxonomies, i went through my articles (posts) using the bulk edit function to 'tag' all the articles in the new custom tag-subjects
By using the bulk-edit feature, this saved me loads of time, but in doing so meant i could only add one tag at a time - however, cetain articles needed to be tagged with multiple tags, so they would show up in the repeated use of bulk edit many times
Here's where it got weird....
Every time i added a new tag to a post and hit the 'update' button, it would increase the post count for that article by +1
I know that sounds a bit crazy, as an article does not have a post count, so the best way to explain it is with an example
1) Go to our sites archive page http://f1stockcars.com/about/archives/
2) Look over to the right for our custom "Drivers" tag-cloud
3) Near the top is is a driver called "Colin Goodswen"
4) Hover your mouse on this driver and it says "12 Topics"
5) Click the name though, and you'll find he has just ONE topic
The reason for this is simply because i had to add multiple "driver" tags to that particular article, and each time i hit the "Update Post" button it (as i said before) increased the post count for that article by +1
And it's not just a one-off... virtually EVERY single driver tag has the incorrect post count assigned to their name
I decided to see if this was an issue unique to the 'Bulk Editor' by going into the standard single (full) Post Editor. Without editing a single thing within the post i simple hit the 'Update' Post button. I went back to my archive to check the post count for tags associated with that post, and they had all increased by +1
I think that's about all the information i can provide on how to recreate the bug.
This now means there is not just the fact it's giving wrong information about post counts to our readers, it also means our tag-cloud's appearance is completely wrong, and tags with only one article are being emphasized over other tags with many articles
Change History (11)
#4
in reply to:
↑ 2
@
15 years ago
Replying to dd32:
Do you have any other post_types registered to that taxonomy as well by any chance? (The Term count is global accross ALL taxonomies, I was under the impression that it doesnt increment it each time you add it, rather, it re-calculates it each time)
OK, well first off i should declare, i am far from any sort of expert on Wordpress, that much should be obvious from my confusing bug report, i get very confused about the terminology and find it difficult to explain things - sorry about that..
but i'm going to go out on a limb here and say i am fairly sure that the answer to your question is no.
I simply followed a guide on Justin Tadlock's personal blog about implementing custom taxonomies
I copied his code verbatim, and put code in my functions.php file to create 3 non-hierarchical custom taxonomies (Championships, Stadiums, & Drivers)
These appeared in my admin area under the 'Posts' menu, and in my 'edit posts' area - and i just entered all the new "tags" i wanted for each new "tag subject"
Definitely nothing particularly advanced
Hope that helps clear any confusion
#5
@
15 years ago
If this is related to my bug then a work around is to create your entry twice. Create one entry in the regular post type that has the same permlink as one in a custom post type and you should be able to see the entries you made in the custom post type, when you click on the tag or category for that entry.
Hope that helps.
#7
@
15 years ago
I have noticed tonight something else, that i'm sure is related to this bug. I'm not sure if i just add it to the comments here, or if i am supposed to update the original bug report - i will probably do both and let a moderator sort it out as applicable
I have drafted in article (post) that is yet to be published. While doing so i had to create a new "driver tag" (drivers name not yet listed in the custom "drivers" taxonomy)
As before, while saving the draft a few times this artificially increased the 'post count' for that tag
So now that "driver tag" appears in my "Drivers" tag cloud, and is listed as having 2 topics associated with it... but of course it is just one post, and has not even been published yet (at time of writing this comment) - So when you click on that tag, the site just throws up a 404 "We could not find what your looking for" Error
Which is not particularly an ideal situation, to say the least
I don't actually understand how this Wordpress Trac works, or understand the grammar associated with it... but has anyone looked into this bug? Does it exist and are people working on it? I see that the milestone has changed from 3.1 to Triage, but no idea what that means.
I'm about 99% sure it is a bug, and nothing wrong with my theme/code... but that 1% doubt is niggling at me, and i'd like to know if i just need to sit patiant and wait for a fix, or try and discover what has gone wrong with my sites code
#8
@
14 years ago
- Keywords reporter-feedback added; custom taxonomy post count removed
- Milestone changed from Awaiting Triage to Future Release
Someone will need to dig into this further.
Do you have any other post_types registered to that taxonomy as well by any chance? (The Term count is global accross ALL taxonomies, I was under the impression that it doesnt increment it each time you add it, rather, it re-calculates it each time)