[bbDev] Using bbPress postings in WP-Widget-Sidebar

Mainframe-Junkie Mainframe-Junkie at gmx.net
Sun May 7 08:55:58 GMT 2006


If you like to show the last posts of bbPress on your WP-Blog it's very 
easy ....
In my case i have NOT integrated the WP- and bbPress-Users, if you have, 
you have to change more than described here, by joining the bbPress- and 
WP-Tables.
Just grab phphpBB Latest Entries (1.0.4) from 
http://wp-plugins.net/plugin/phphpBB/
Open phphpbb.php in an editor and change the following lines :
(Line 55)
$query="SELECT `user_id`, `username` FROM `".$prefix."users` WHERE 
`user_id`=$row[poster_id] LIMIT 1";
to
$query="SELECT `id`, `user_login` FROM `".$prefix."users` WHERE 
`id`=$row[poster_id] LIMIT 1";
(Line 61)
$values[]='<a 
href="'.$url.'viewtopic.php?p='.$row['post_id'].'#'.$row['post_id'].'">';
to
$values[]='<a 
href="'.$url.'topic.php?id='.$row['post_id'].'&replies='.$row['post_id'].'">'; 

(Line 63)
$values[]='<a 
href="'.$url.'profile.php?mode=viewprofile&u='.$row['poster_id'].'">';
to
$values[]='<a href="'.$url.'profile.php?id='.$row['poster_id'].'">';

Now install the plugin, activate and customize it.

Have fun and thanks for bbPress

Oliver



More information about the bbDev mailing list