[Resolved] categories in wp_posts all show ‘0’?
Let me first say my site is working just fine. However, I want to make a static page pulling the titles of all posts in one particular category (audio). I figured I would modify one of the BX_ functions to do that, and make my own function to pull the list.
Seems simple enough so I looked up the category # I wanted, which was 9. However when I took a peek in wp_posts and looked at the post_category column – they are *all* 0’s, all the way down!
How can this be – my categories work fine. But if the category numbers are not in posts, how can filter and pull only those posts?
I was going to use this line:
$posts = $wpdb->get_results(“SELECT ID, post_title FROM ” . $wpdb->posts . ” WHERE post_status=’publish’ AND post_category=’9′ ORDER BY post_date DESC LIMIT ” . $limit);
But now I am stuck… is the 0 just a placeholder or something or is something wrong with my table?
- The topic ‘[Resolved] categories in wp_posts all show ‘0’?’ is closed to new replies.