eagano (@eagano)

Forum Replies Created

Viewing 7 replies - 1 through 7 (of 7 total)
  • @ctsttom – In order for a user that was registered in WordPress to have any authority in bbPress, they need to have the option ‘bb_capabilities’ in their user metadata. This does not have anything to do with the role maps in bbPress. Those role maps only affect users that are registered within bbPress that need to have capabilities inside WordPress. I think you are having the same problem that I had – you need to go the other direction. You need a default capability in bbPress for a new user registration in WPMU.

    There are two ways to do this:

    1) go to your bbPress admin panel, drill into each new user that was registered in WordPress, edit their profile, and assign them a ‘User Type’

    2) use my shiny new WordPress plugin that creates a default capability of ‘member’ in bbPress for users that are registered in WordPress


    I would be interested in any feedback you have. There are two caveats to this plugin:

    1) it does not handle any users registered in WordPress that existed before the plugin was activated, you’ll have to do that manually (but you get the idea and could handle this with a mass SQL)

    2) there is no logic to determine which bbPress User Type to use, I just start with ‘member’ and assume that I’ll manually set admins/moderators, and further that everyone with a login should be able to post.

    Let me know what you think!


    Does the page respond at all when you click ‘Add Forum’? Does it refresh and do nothing? Or does the page not even refresh? And you are able to do all the other admin tasks?

    If you just click ‘Add Forum’ with no input you should get the red error message box below the add form with “An unidentified error has occurred.”.

    There are at least two nonces for security and quite a few hidden fields that need to be there. Here’s what I’m seeing:

    <p class="submit">
    <input type="hidden" name="order-nonce" value="beb39845e6" />
    <input type="hidden" name="_wp_http_referer" value="/bb-admin/content-forums.php" />
    <input type="hidden" name="_wpnonce" value="84424fd1b7" />
    <input type="hidden" name="_wp_http_referer" value="/bb-admin/content-forums.php" />
    <input type="hidden" name="action" value="add" />
    <input name="Submit" type="submit" value="Add Forum »" tabindex="13" />

    I’m wondering if the HTTP POST is happening with no result, or if the submit is not even working. If you don’t get any error message when you click submit, it’s probably an ajax problem.

    Ooops – please see my conversation with Donncha in the ticket above.

    The short story: defining COOOKIEHASH as md5(get_option(‘site_url’)) will work for the main blog but not any other blogs if you are using VHOST (subdomains).

    There is a fix/hack: calculate the md5 hash of your domain, and use that value to define COOKIEHASH.

    define('COOKIEHASH', md5('http://yourdomain.com');

    No subdomains, no trailing slashes, will work fine.

    You can also get this value from bbPress speedup settings, found at Settings, WordPress Integration, and the bottom of the page.

    $bb->authcookie = 'wordpress_biglonghashvalue';
    $bb->secure_auth_cookie = 'wordpress_sec_biglonghashvalue';
    $bb->logged_in_cookie = 'wordpress_logged_in_biglonghashvalue';

    In your wp-settings.php,

    define('COOKIEHASH', 'biglonghashvalue');

    musnake –

    One thing you could try, which seemed to get everything working for me. Copy the hashes/salts directly from your wp-config.php file and prefix each one with BB_. Might be excessive, but seems to work for me.

    define('AUTH_KEY', 'blah');
    define('SECURE_AUTH_KEY', 'blah');
    define('SECURE_AUTH_SALT', 'blah');
    define('LOGGED_IN_KEY', 'blah');
    define('SECRET_KEY', 'blah');
    define('SECRET_SALT', 'blah');
    define('LOGGED_IN_SALT', 'blah');


    define('BB_AUTH_KEY', 'blah');
    define('BB_SECURE_AUTH_KEY', 'blah');
    define('BB_SECURE_AUTH_SALT', 'blah');
    define('BB_LOGGED_IN_KEY', 'blah');
    define('BB_SECRET_KEY', 'blah');
    define('BB_SECRET_SALT', 'blah');
    define('BB_LOGGED_IN_SALT', 'blah');

    I just couldn’t get the descriptions in bbPress setup page to match all the keys in wp-config.php, so I copied them all over in a brute-force cop out. I am on a subdomain install, not folder, so this might not help.

    I have entered a ticket for WPMU:


    musnake –

    I think this must be a big source of the problem for MU and getting it to work with bbPress. And why some get integration to work (standalone) and other can’t (wpmu).

    In the WP standalone install, it does indeed appear to be there (is that where you got the code above?).

    In WPMU 2.6.2 (https://mu.wordpress.org/latest.zip) wp-settings.php, line 317:

    // Used to guarantee unique hash cookies
    $cookiehash = '';
    * Used to guarantee unique hash cookies
    * @since 1.5
    define('COOKIEHASH', '' );

    if( defined( 'MUPLUGINDIR' ) == false )
    define( 'MUPLUGINDIR', 'wp-content/mu-plugins' );

    if( is_dir( ABSPATH . MUPLUGINDIR ) ) {
    if( $dh = opendir( ABSPATH . MUPLUGINDIR ) ) {
    while( ( $plugin = readdir( $dh ) ) !== false ) {
    if( substr( $plugin, -4 ) == '.php' ) {
    include_once( ABSPATH . MUPLUGINDIR . '/' . $plugin );

    Want to know the funny part? I actually debugged it instead of going to the source in WP standalone. At least I came to the same conclusion. This should probably be reported as an MU bug – I’ll let Donncha know.

    I have released the enable WPMU users part as a plugin.

    You can download it here:


Viewing 7 replies - 1 through 7 (of 7 total)