Info
- 3 posts
- 2 voices
- Started 2 years ago by rainbow_lazer
- Latest reply from _ck_
- This topic is not resolved
Show bbPress tag cloud/hot tags in WordPress
-
- Posted 2 years ago #
Hi, I'm trying to figure out how to display bbPress' tag cloud from the sidebar in WordPress. I've googled a lot, but can't seem to find anyone who's done this.
I've hacked a temporary solution that displays the topic tags from bbpress as a list in the wordpress sidebar, but I'd really love to have the size formatting as well.
<?php
global $wpdb;$taglist = $wpdb->get_results("select name from bb_terms","ARRAY_N");
$number_of_tags_to_show = 10;for ($count = 0; $count < $number_of_tags_to_show; $count++)
{
if($taglist[$count][0])
{
$tag = str_replace( " ", " ", $taglist[$count][0]);echo '
- <a href="http://www.mysite.org/forum/tags.php?tag=';
';
echo $tag;
echo '">'.$tag.'
}}
?>Any suggestions for how to access bb_tag_heat_map from inside WordPress?
-
- Posted 1 year ago #
OK, I figured it out. Here's a link to my solution:
http://rainbowlazer.com/scripting-programming/php/bbpress-tags-from-in-wordpress/
-
- Posted 1 year ago #
There's a much better way.
My "Hot Tags Plus" plugin makes the output into a static file, already compiled so there's zero overhead the next time you want to display it.
You can then just use php's
readfileto include it on any page you want outside of (or even inside) bbPress, you just have to figure out the full path to it on the server. -
You must log in to post.