• Hello after the upgrade of WordPress 2.3, the category number’s seem to have changed.

    Even though Dashboard –> Manage –> Categories lists a category ID as #8, it seems to actually be a different number now (it is now #4) when using plugins to call that category number (like wp-postratings).

    Now I added a new category Dashboard shows it as ID #114 but it seems to be using a different number. Any clues on how to find that number without cycling through all the numbers ?

Viewing 6 replies - 1 through 6 (of 6 total)
  • Manage->Categories shows me the correct ID’s. If I use phpMyAdmin to look at the wp_term_taxonomy table, the term_id field is the category ID.

    Thread Starter nelson-ray

    (@nelson-ray)

    prior to upgrading wordpress 2.3 I had some categories created. then I deleted a few categories. category news is listed as ID #8. after the upgrade to wordpress 2.3, in manage –> categories the id for category news is still shown as “8”. but when using postratings plugin, the category would not list unless I changed the number to “4”. this tells me because of the deleted categories prior to the upgrade, after the upgrade, wordpress somehow truncated the id numbers.

    everything works though so its not a huge problem, but the small problem I have now is that I just created a new category and wordpress gave it the id #114 in manage –> catgories. Of course the postratings plugin does not show anything so I have to find out what the actual id # is. This is more difficult since its #114 and there are a lot more numbers now.

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.ads-software.com Admin

    Then the postratings plugin is the one with the problem. Make sure it’s been upgraded to deal with WordPress 2.3 correctly, because the ID numbers on the Manage screen are correct. If you have to use different numbers, then the plugin is broken.

    Thread Starter nelson-ray

    (@nelson-ray)

    I have upgrade to postratings 1.20, which is compatible with wp 2.3. I asked over there and they mentioned “hmmm, maybe you can try posting this issue over at WP.org forums about the categorys -> tags issue as I think you might be right about the deleted thing, since mysql doesn’t use back deleted id.”

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.ads-software.com Admin

    I really have no idea what that means. My only suggestion is to ask them how they’re using the ID and if they’re doing direct database work, why? They really should try to avoid direct hits to the database in order to maintain compatibility. If they need categories and such, there’s plenty of core functions that will allow them to retrieve categories instead of doing direct DB work, and these will likely continue to work in the future, whereas the database itself seems to change some with every new release.

    Without going through their plugin’s code, all we can do is point to it and say it has the problem. They know their code already, so they would be the ones to talk to.

    Thread Starter nelson-ray

    (@nelson-ray)

    ok thanks I solved my own problem. not sure where problem lies, but because I had delted categories prior to the upgrade, it seems with the plugin at least, all my category numbers are off by the amount of the deleted categories. Category 8, works only if i call category #4, category 114 works only if I call #110. not a problem for me now as i know which id numbers to call. thanks for your help.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Need help finding category id Number’ is closed to new replies.