Skip to:
Content
Pages
Categories
Search
Top
Bottom

Integration and second database


  • Andrea Rennick
    Member

    @andrea_r

    Has anyone got bbpress to integrate either with WP or WPMU off a second database? Yes, I read the documentation, which isn’t clear as to what I’m supposed to do. I tried many different things, resulting in different errors each time, none of which actually used the wp_users table in bbpress. The last change almost did it, but it somehow horked my WPMU install when I went to add a user to see which db it plunked it in (neither, as it turns out – it seems to be in limbo).

    To start, I had a local copy of MU working, and I got an install of bbpress working as well. It’s just getting the two of them hooked up is where I run into issues.

    Any ideas? Tips? Step by step instructions? :D

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

  • mozey
    Member

    @mozey

    Okay, you need to pick up the plugin which lets you syncronize users between bb and wp. Its somewhere around, this site.

    andrea_r,

    What is the goal? Are you trying to to have mu and bbPress share the same user table? bbPress and mu are using different databases (as opposed to different tables in the same database)?

    I can help, but I need to know exactly how things are and how you want them to work.

    I think this is your situation (apologies if I misunderstood you):

    You have mu and bbPress installed and working off of different databases. You want bbPress to store its content in that separate database, but you want it to draw its users from mu’s database.

    If that is the case, this is what should work. The top of bbPress’ config.php should look like:

    //These are for the information about the database into which bbPress should store its content

    define('BBDB_NAME', 'bbpress');

    define('BBDB_USER', 'username');

    define('BBDB_PASSWORD', 'password');

    define('BBDB_HOST', 'localhost');

    // This is the information about mu's database. bbPress will look for users in this database

    define('USER_BBDB_NAME', 'mu');

    define('USER_BBDB_USER', 'mu username');

    define('USER_BBDB_PASSWORD', 'mu password');

    define('USER_BBDB_HOST', 'localhost');

    // You just told bbPress to use that mu database to look for users, but it doesn't yet know the name of the *table* to use.

    // Change 'wp_users' and 'wp_usermeta' to be the table names of mu's user tables.

    define('CUSTOM_USER_TABLE', 'wp_users');

    define('CUSTOM_USER_META_TABLE', 'wp_usermeta');


    mozey
    Member

    @mozey

    DUDE

    that SHOULD go in the “documentation -> integration with wp”


    Andrea Rennick
    Member

    @andrea_r

    DUDE, that was it exactly – I was missing this part:

    // You just told bbPress to use that mu database to look for users, but it doesn’t yet know the name of the *table* to use.

    // Change ‘wp_users’ and ‘wp_usermeta’ to be the table names of mu’s user tables.

    MU also has a wp_users table, which so totally didn’t work when you point it there. Will try the above and report back.

    (the plugin didn’t help btw, at least not originally)


    Andrea Rennick
    Member

    @andrea_r

    huh. Still spews erros:

    “bbPress database error: [Table ‘bbpress.wp_users’ doesn’t exist]”

    So it’s still looking in the bbpress db instead of the MU one.

    Fiddling with “// The rest is only useful if you are integrating bbPress with WordPress.

    // If you’re not, just leave the rest as it is.” doesn’t change things either.

    If I comment out the define custom user table, it works without errors, but still doesn’t share user info. Weird.

    Any hints or where I’ve overlooked thing? Something else to edit?

    Also, I should mention I’m doing this on a local server.

    Are you using bbPress 0.72 or some older pre-release version?


    Andrea Rennick
    Member

    @andrea_r

    Nope. Fresh from the download page. I did check db.php and it does have code in there if the 2nb db is declared, it just seems not to catch it.

    I’m gonna try it stuffed away on on a live server somewhere. I don’t want to accidentally hose my MU install until I know I can get it working.

Viewing 7 replies - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.
Skip to toolbar