MyBB Community Forums

Full Version: How can I use my registration / login system for the forum
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi, I've been searching for an answer for this question for a while, but unfortunately I found only fragmented topics that didn't help me at all.

I own a site with access only for members, so the visitor must register to use the site.

I want to find a solution so that I can integrate the forum with my site. Specifically I want users who register on my site to register on the forum automatically. Same for sign in.
I have my own security system and the database does not use WordPress etc.

How could I do this integration? Are there any plugins for this? What do I have to change to mybb to work as I explained above? I am not expressly interested in managing the users in my database, but I definitely want when logging in or registering on the site to login / register automatically in the forum. I am aware that there is no default plugin for this, I was thinking of api or something.

You'll have to create the users automaticaly in your forum, using a query looking like:
INSERT INTO mybb_users (username, password, salt, email, usergroup) VALUES (....)
The password (in database) is done like this: md5(md5($salt).md5($password)) where $password is the user password and $salt a random value (that you have to put in salt in db)

To keep the user logged, you'll have to fill the mybb cookie the same way the forum does.