MyBB Community Forums

Full Version: myBB Integration With Customized Website
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
I am making a custom website for a friend, and want to integrate myBB with this site. Basically, I just need to make the user database work with my site. How would I go about doing something of the likes of that?
Changing MyBB to work with your existing user database would be alot of work to incorporate everything. Stay turned for MyBB Gold which will allow you to create/use your own "authentication" modules for user authentication with another database or product..
I haven't actually made the user database yet. Could I just send queries from the website to the forum user database? Or would that also be hard?

Thanks,
-yaggles
Yaggles Wrote:I haven't actually made the user database yet. Could I just send queries from the website to the forum user database? Or would that also be hard?

Thanks,
-yaggles

That's easier to do Smile

Something like this:

mysql_connect('yourhost', 'youruser', 'yourpassword');
mysql_select_db('yourdb');

$username = $_POST['username']; //Username from your login form
$password = md5($_POST['password']); //Password from your login form

$result = mysql_query('SELECT password FROM mybb_users WHERE username = "' . $username . '" LIMIT 1');

if (mysql_num_rows($result) > 0) {
// There is a user
$user = mysql_fetch_array($result);

if ($user['password'] == $password) {
// Password is correct, log the user in
}
else {
// Password is Incorrect.  Punish the user!
}
}
else {
//User does not exist
}
Chris Boulton Wrote:Changing MyBB to work with your existing user database would be alot of work to incorporate everything. Stay turned for MyBB Gold which will allow you to create/use your own "authentication" modules for user authentication with another database or product..

hey Chris, can you please ellaborate on this as I have contracted a company working on this at the moment developing an entire community around the myBB usertables....

cheers,
Kimmo
In terms of user authentication such as checking the password, you'll be able to use your own custom modules to do so - these modules will allow you to check a third party database for a matching username/password and then return it to MyBB.
Is myBB Gold a paid version? Because that's what most Gold versions are: expensive. Toungue

-Yaggles
MyBB is free and always will be, even Gold!
ok cool! Big Grin
Chris Boulton Wrote:In terms of user authentication such as checking the password, you'll be able to use your own custom modules to do so - these modules will allow you to check a third party database for a matching username/password and then return it to MyBB.

Is there any word on if this feature will be making it into mybb still?
Pages: 1 2 3