compare WordPress tags to BBpress tags. Relevant posts.
-
Hi, I’m trying to list topics from the forum in a WP post. I’m wanting to just show the topics that have the same tags as the particular post that is being viewed.
This is basically a display relevant posts. How can this be done? I’ve tried a bunch of PHP, but I’m not having luck navigating the codex between the two databases. I’ve mucked around alot, but I can’t get beyond the basic display the last 10 posts functionality.
Here’s where I’m at: HELP?
<?php
global $wpdb;
$query=”SELECT * FROM bb_topics WHERE topic_status=0 ORDER BY topic_time DESC LIMIT 10″;
$results=$wpdb->get_results($query);
foreach ($results as $result) {echo “
- topic_id.”‘>”.$result->topic_title.”
“;}
?>
- You must be logged in to reply to this topic.