It’s about time everyone was let in on the progress we have made towards version 1.0 of bbPress.
I expect the next alpha release to be made sometime in the next two weeks. This release will include our first implementation of Pingbacks both to and from your bbPress installation. The first draft implementation of this is now in trunk.
Also to be included in the next release is an implementation of the pseudo cron feature from WordPress. This will allow plugin developers to schedule jobs in the future or on a regular basis. It is 100% compatible with the WordPress implementation, so the existing documentation is all you need to get started with using it.
To enable cron I’ve included the very new WP_Http class in BackPress. This new class is a robust HTTP fetcher which is meant to replace the Snoopy class in WordPress. This will allow all sorts of RESTFUL services to be utilised within bbPress plugins, like fetching data from other pages, embedding search APIs and even pulling data from WordPress via RSS or XML-RPC.
On the drawing board is the beginnings of an XML-RPC publishing interface. This will make it easier to use bbPress as a data store for more exotic clients like custom flash applications and XML-RPC desktop clients. It also opens the door to creating an iPhone app for bbPress much like the existing WordPress iPhone app.
An alpha version of bbPress’ new export/import format and tools has also landed in trunk thanks to our Google Summer of Code student Dan Larkin. You can read a little more about that at the BBXF website.
There will also be several fixes for bugs found by our courageous alpha testers.

There are a few changes in 0.9 which plugin developers need to be aware of. So here are some notes to help you get your plugins running under the new release.
First of all if you want to detect whether someone is running version 0.9 or higher you can use this code:
if (version_compare(bb_get_option('version'), '0.9-z', '>=')) {
// Tell us what your name is!
echo('This is bbPress version 0.9 or higher.');
}
Note: The “-z” on the end will make sure you catch all pre-release versions of bbPress 0.9 as well, like “0.9-dev”.
There are a number of no-longer-used functions from previous versions that we provide backwards compatibility for in bb-includes/deprecated.php. So you may not have noticed that your plugin is still using some of them. In version 0.9 we have made detecting your use of these a little easier by providing a way to report their use via PHP errors when they get called.
Just open up the file bb-includes/deprecated.php and change the “BB_LOG_DEPRECATED” constant at the top of the file from the boolean false to true.
Now if one of the many deprecated functions gets called it will be written to the same place that your PHP errors are written (either an error log or to the screen). The errors will tell you which deprecated function was called and what to replace it with.
A whole bunch of PHP constants have been deprecated in this release in an attempt to standardise our naming of constants. For now we are providing backwards compatibility for the older constants, but you should check your own usage of these and change them to use the correct ones.
Unfortunately there is no way to log these to errors, so this is a manual find and replace task. Two arrays of constants and their replacements can be found in bb-settings.php starting at line 304.
There is a new directory called bb-plugins in the root of the bbPress codebase. This directory is reserved for plugins that are distributed with the core bbPress files. Third-party plugins should still be stored in a separate my-plugins directory. Do not instruct users to install files in the bb-plugins directory, they are functionally no different from each other, except that the bb-plugins directory has more potential to be destroyed during user upgrades. You have been warned!!!
Formerly we stored active plugins in a serialized array where each plugin was identified using it’s relative path from the my-plugins directory, e.g. “plugin.php” or “folder/plugin.php”. With the advent of core plugins there exists a need to differentiate between “core” and “user” plugins.
We are doing so by prefixing either “core#” or “user#” to the plugin, so the previous examples in the my-plugins folder would become “user#plugin.php” and “user#folder/plugin.php” in the same serialized array.
Similarly we are changing the way the active theme is stored. Instead of saving the absolute path to the active them, instead we are simply storing it’s name, i.e. the name of the directory it is contained prefixed with either “core#” or “user#” depending on it’s location.
The correct way to register a function to run on plugin activation is like this:
function foo() {
echo 'bar!';
}
bb_register_plugin_activation_hook(__FILE__, 'foo');
Provided that the file you are registering in is the base plugin file. Do not hardcode the plugin file name as users may move them into directories inside the plugins directory.
Registering a function to run on plugin deactivation is similar except you need to call bb_register_plugin_deactivation_hook()
With the inclusion of built-in avatar support you may think that all the time you spent on that custom avatar plugin is wasted. But actually, it is quite the opposite. By incorporating avatar calls into the default templates and providing a fully pluggable and filterable get_avatars() function, integrating avatars is actually easier than ever.
One thing that might have slipped by without enough attention is the new plugin browser which was recently implemented. Go have a play and check out all of the newness.
And finally, a big thanks to all our plugin developers for contributing so much to the bbPress community. If you have any ideas about how we can help you build better plugins, then let us know.

Most of those who follow the tech-blog-o-sphere* will be aware of the recent financial news regarding Automattic, the company that more or less stewards bbPress’ production.
For the rest of you here are some links that cover the story.
Some people may be wondering what this news means for bbPress. Well, for a start this funding has already impacted on the project as it made my full-time employment with Automattic possible three months ago when the arrangement was in it’s early stages. But more importantly it now allows Automattic to have the financial security to back bbPress into the foreseeable future.
We have some awesome things in the pipe including improvements to the bbPress core, the bbpress.org website and, in the not too distant future, the launch of a hosted community service by Automattic based on bbPress.
In the meantime, we will be ramping up the pace of development and attempting to bring out some of the new features that have been on the “to-do” list for far too long. Features which we hope will help to differentiate bbPress from the crowd and make it a truly useful tool for building online communities.
* NB: Not an actual word
With the introduction of the new BB_Query_Class in bbPress 0.8.3, the old method of adding custom “views” to bbPress has been removed. You should no longer directly manipulate the $bb_views array, nor does the bb_views hook work.
To add a view, you should instead use a new function: bb_register_view(). Also available is bb_deregister_view() for removing the default views or views added by other plugins.
function my_plugin_views() {
/*
bb_register_view(
$view_slug,
$view_title,
$bb_query_argument_array
);
*/
bb_register_view(
'more-than-5',
'Topics with more than five posts',
array( 'post_count' => '>5' )
);
bb_register_view(
'old-timers',
'Topics started before 2005',
array( 'started' => '<2005' )
);
// Remove default 'Topics with no tags' view
bb_deregister_view( 'untagged' );
}
add_action( 'bb_init', 'my_plugin_views' );
If you really need more complicated queries, you have the following filters at your disposal, just by registering your view in the above fashion (assuming the $view_slug is “my-view”).
bb_view_my-view_distinctbb_view_my-view_fieldsbb_view_my-view_joinbb_view_my-view_wherebb_view_my-view_group_bybb_view_my-view_havingbb_view_my-view_order_bybb_view_my-view_limitIf that sounds complicated, it probably is
Most plugin developers will never have to do much besides filter a join or where here and there.
WordPress 2.3 is now available.
I mention that because the current version of bbPress (version 0.8.2) is not compatible with WordPress 2.3 if you are loading both scripts at the same time. If you’re not loading both scripts at the same time, everything is fine.
A new version of bbPress will be coming out in a day or two as soon as we get done testing it, and that version will fully compatible with the latest version of WordPress once again.
bbPress has twenty or so functions that select groups of topics or posts from the database. Some of them do very specific things, and some of them do something only slightly different from another such function.
Maintaining this large group of functions and keeping them all consistent was beginning to become a nuisance. Additionally, it was annoying to have either to write a whole new function or to hack filters into and onto an existing function every time a new database query was needed.
To help alleviate both of these problems, the next version of bbPress will come with a BB_Query class, which all of the above referenced functions will use.
For developers and plugin authors, this means it’ll will now be really easy to query the database for posts and topics based on whatever arbitrary criteria is needed. For users, the following couple paragraphs will be boring, but see the news below
As an example, the following code will select all the topics written by mdawaffe in June of 2007 and having the “bbPress” tag and will sort those topics by their start time.
$topic_query = new BB_Query( 'topic',
array(
'topic_author' => 'mdawaffe',
'started' => '2007-06',
'tag' => 'bbpress',
'order_by' => 'topic_start_time'
)
);
$topic_query->results; // Here's the array of topics the query returned.
Both the incoming parameters and the SQL query that the class generates are highly filterable (in a way that’s backward compatible with the current version of bbPress), so further customization should be easy. Also, the BB_Query class can automatically handle pagination, caching and more, so you can relax and get on with more interesting things.
In the end, though, we write code for users, not for developers; we want the user experience to be as pleasant as possible. With all these new bells and whistles, users get some pretty cool new features.
The default theme will now let you constrain your search to an individual forum (and adding that ability into other themes will be super easy). Adding extra constraints (like searching by tag or author) will be easy too.
In the admin section, you can search both topics and posts by a number of criteria.
Next stop… Pingbacks. (sshhh! It’s a secret!)
For those of you interested in keping closer tabs on bbPress development, we now offer a new bbPress Trac Mailing List. Subscribers to this “read-only” list will receive an email every time a ticket on bbPress’ development center is changed. I tried generating an RSS feed for such changes, but my Trac-fu is pretty poor. So, email it is.
The original bbPress Development list is still around, of course, for discussions and ideas.
Sign up for both!
bbPress has seen some pretty interesting development over the past weeks. Just to keep people in the know, and since many were expecting bbPress 0.80 to come out a couple weeks ago (we’re still learning here
), here’s a short list of some new features that will be in the next release.
topic_resolved column from the database. No more “this topic is not a support question” strangeness for forums that aren’t support forums. Those people that want to keep such functionality around will be very pleased with Aditya’s Support Forum plugin.config.php. This is pretty nice; you’ll be able install a completely “clean” copy of bbPress in, for example, a directory named public_html/forums/ and have your templates stored in public_html/templates/, your plugins stored in public_html/plugins/ and your config.php file in public_html/config.php. None of your custom stuff ever has to be in bbPress’ public_html/forums/ directory, so upgrades will be a snap.Of course, we’re still working out some bugs and have a few more important things to get done before the next release, but that’s a preview of things to come.
Historically, bbPress has dealt with time in a… shall we say “interesting” manner. Without going into technical details, bbPress constrained you, the person installing bbPress, to set it’s internal timezone to match exactly that of the server it was running on.
That’s ridiculous.
What if you lived in Brisbane, but your servers were held captive in Cleveland and set to GMT? I’ll tell you what if: only after lots of trial and error were you able to get rid of that strange “-1 years ago” bug seen everywhere on your site. But then you were stuck at some arbitrary timezone.
With bbPress 0.8, all that has changed. You can set bbPress’ timezone to anything you like completely independent of where you are and where your server is.
But that’s not good enough, you cry! You want your users to be able to set their own timezones too! Well, bbPress doesn’t do that, and may never, but a plugin can and does! See the “proof-of-concept” User Timezones plugin.
Additionally, theme designing and tweaking is now much easier with respect to time template functions like bb_post_time(), topic_time(), and topic_start_time().
bb_post_time( 'F j, Y, h:i A' )
-> “February 8, 2007, 10:57 PM”
bb_since( strtotime( bb_get_post_time() ) )
or something equally heinous. No longer. All the default templates now use the much more pleasant method described above. If you based any custom templates off of the old default templates, they will probably still work since the changes made were almost completely backward compatible. If you run into any problems, remove from your templates any mention of strtotime(), bb_since(), and bb_offset_time() as the bits you need from those functions should now work automagically.
bb_get_post_time( 'timestamp' ), and the MySQL date: bb_get_post_time( 'mysql' ).Much more pleasant ![]()
bbPress 0.8.2 introduced a new way of counting how many pages worth of information there were to display (how many pages worth of content, for example, there are to display in a user’s profile): MySQL’s FOUND_ROWS() function. It works very well for most bbPress sites.
It cripples large sites.
After upgrading the WordPress.org Support Forums to bbPress 0.8.2, the server very quickly melted into a belligerent heap of protesting electrons. Most of this was bbPress’ fault (though MySQL shares some of the blame).
FOUND_ROWS() seemed to be a “magic bullet” everywhere it was tested (including the bbPress.org forums). While that impression should have made me very wary, instead it led me to use SQL_CALC_FOUND_ROWS (the SELECT query companion to the FOUND_ROWS() function) in places that really didn’t need it.
Mea culpa.
Because of that misuse and because of MySQL’s poor SQL_CALC_FOUND_ROWS optimization, sites with hundreds of thousands of topics (such as the WordPress.org support forums) will actually be slower (much slower) using bbPress 0.8.2 than they were using bbPress 0.8.1. This despite the other database and query optimizations that went into bbPress 0.8.2.
A fix for this bug and fixes for those others we collect in the coming weeks will be packaged into a new release.
Until that time, if you have a large site (where large probably means “tens of thousands of topics or users”) that has noticeably slowed since upgrading to bbPress 0.8.2, there is a solution. Use the current code available from the bbPress svn repository’s 0.8 branch (available via svn or zip file).
Our Trac system lets you see the changes in that branch since the release of bbPress 0.8.2. In particular, this performance issue was fixed in changeset 867.
On most sites though, the slowdown will probably not be noticeable. Unless your site is getting bogged down by bbPress’ use of the database, there’s no need to change anything.
After a month of waiting, bbPress 0.74 is finally available for download. Even if it did take a while, we’ve fixed a several important things.
Aditya has a great overview of the changes, but here’s a few of the bigger ones.
init hook has been changed to bb_init for better compatibility with WordPress.We’ve got some slick new features we’re working on for the next release (did someone say “themes”?), so stick around….
In the meantime, read on for some more technical details about this release.
There have been several changes at bbpress.org over the last couple weeks.
First off, the content of this site has been updated substantially. There is now somewhat more thorough documentation, and a more fleshed out about page.
Second, bbPress’ code has been made just that much more pluggable and convenient by syncing several of its core functions with those of WordPress.
Third, Bryan Veloso has whipped up some stylin’ new style for the bbPress default theme. People expect great things from Bryan, and, amazingly, he just keeps raising their expectations. Tips on how to create your own themes can be found in our Customization Documentation.
Fourth, the bbPress Trac has been moved to http://trac.bbpress.org/. The tickets have all been cleaned up to make way for…
Lastly, the imminent release of bbPress 0.72. Expect an announcement and some forums (no!) here on bbpress.org within the next couple of days.
We’ve now gone around the site, swept up the corners and shined the mantel. If you visited when things first launched you’ll notice everything is tidier now. Please take a look around! The forums are already starting to buzz.
I’m really excited about getting bbPress out in the public with its first public release. Michael has been doing great work and I think today, just as two years ago when I first wrote bbPress, the forum arena is in dire need of some fresh air.
bbPress is also technically pretty fun if you’re a geek. It’s how I would’ve written WordPress if I could go back in time with everything I know now. The code is clean, fast, consistent, and extensible.
If you’re looking to integrate bbPress and WordPress, life just got a little easier.
I’ve done a quick pass over the bbPress API to clean up the obvious API oddities. I’ll also soon be looking for redundant actions and filters. This may break some of your plugins, but will hopefully make things easier for everyone in the end.
There will likely be quite a few changes over the next weeks. Look ahead to a better bbPress!
bb_add_user_favorite: used to pass one serialized array. Now passes two parameters.bb_remove_user_favorite: same.resolve_topic moved to after DB update.close_topic, stick_topic, unstick_topic.opentopic moved to after DB update and renamed to open_topic.topic_resolution added: filters resolved status. Passes topic_id as an extra parameter.bb_already_tagged: used to pass one serialized array. Now passes three parameters.bb_tag_added.bb_tag_created: used to pass one parameter. Naw passes two. Order has changed.bb_tag_removed: used to pass one serialzed array. Now renamed to bb_pre_tag_removed and passes three parameters.bb_tag_merged. Renamed to bb_pre_merge_tags.bb_tag_destroyed renamed to bb_pre_destroy_tag.There have been a few template changes recently.
post-form.php should no longer have <form> opening or closing tags. These tags are included by the post_form() template tag.tag-form.php and tag_form().edit_form() no longer needs any parameters.login-failed.php has been moved to login.php.open-source: del.icio.us tag/open-source
Development
Software
forum
tools
Wordpress
opensource
open-source
BBPress
I just checked in a new database layer that allows bbPress to connect to a completely separate database for its user information, in addition to just having custom table names. This is very useful if you want a bunch of blogs and forums running off the same user system, but don't want to stuff them in the same database, or if your user information is hosted on a different server or account than your forums are.
Thanks in part to the hard work of Juan Correa (PotterSys) and Ryan Boren, bbPress is now almost completely "gettexted" which means that all of the strings in the software can be translated and replaced on the fly. Some other code improvements have also come along the way.
All SVN changes are now being mailed to our mailing list and I've also fixed up the nightly builds so they're generating correctly now.
We're making some big changes to the bbPress codebase over the next few days, as opposed to the more incremental changes over the past year. bbPress has been working so well we haven't really needed to touch much, but it still needs a good coat of paint before we consider taking it out of alpha, so that's what to watch for.
A quick review of some recent changes.
There have been several changes in the code over the past few weeks. Rather than explaining them in detail, I’ll just highlight the most interesting ones.
PS: A quick reminder that action and filter hooks are always up for grabs. Suggestions welcome!
The users table has been pared down to include only core user information. Additional information about each user can be stored in the new usermeta table. Accessing the information is just as easy as it always was; both the core and the meta information are included in the good ol’ $user object.
For anyone out there twisting their installs around to see what bbPress can do, you only need to know two things:
update_usermeta( $user_id, $meta_key, $meta_value );$user_cache manually; always use bb_get_user( $user_id );Sorry about all the technical whatnot, but it’s a big, exciting change!
In order to help both those who ask questions in a support forum environment and those who answer them, topics can now be given a resolution status. Moderators and the original poster are able to change a topic’s resolution state to “resolved”, “not resolved” or “not a support question”.
After the appropriate interface decisions have been made, resolution status will also be taken into account and reflected in the various default templates.
bbPress is starting to use AJAX for updating various content, which allows us to avoid hard page refreshes. The benefits of this are two fold. First, we only have to update part of a given page instead of the whole thing; we save time, database hits and bandwidth. Second, the user experience is improved (or will be when we figure out the best interface for all the new shiny bits).
Everything should degrade nicely if the client does not support AJAX specifically or Javascript in general.
For any who aren’t subscribed to the mailing list but are still poking away at bbPress, you should know a bunch of globals and functions have been renamed over the past few revisions to make bbPress more interoperable with WordPress. For more information, please reference this mailing list post