View Full Version : Integrating two diff boards!
Is there a hack if this is possible at all that you could sign up a user on two boards on two different servers?
so for instance when I sign up for this board I'm gonna b registered on another board as well?
If you have access to both databases you could easily duplicate the new user code so that it made the inserts to both db's at the same time. You would need to handle the case of the username/email possibly already existing in one of the db's but not the other.
that's what I was thinking too, but if I have the same members on both it won't happen, since when you reg for one your automaticaly reg for the other, and I would import the old users to the new board anyways!
Do you know how to do this?
Any help will be really appreciated!
Yes I do but must ask the question : if both db's have the same user database why not just reference one database?
well I mean if you have two boards not from the same person, like you want that all your users sign up for another board on another server on another database (even because you can't have more than one vbb on the same db) to sign up for your friend's board as well, and your friend is starting so his board had no users
I'm sorry I think I know what you mean know, but how would I reference one database frmo another board? Where would I have to change?
So first you would need to export your users table (the one with the users) and import it into your friend's user table. You know would have the same users. (You would do this using phpMyAdmin easily)
From here I assume you both make the hacks so that a new user at either board would be entered into the other boards database also.
You would need to give your database info to your friend and he would need yours. The hack would be a minor one to member.php.
You also would need to update a user's info on both boards if/when they choose to change their profile (homepage/password/ICQ/etc)
Again this would be a minor change to member.php.
Remember trying to maintain synchronized data on separate databases is not a fun task. What happens if a user regs at your server but your friend's server is down or inaccessible at that moment? You are now out of sync. You could write even more code too make sure a queue is maintained so that the database's can be synched but the hack then becomes tedious. What happens when the user's userids get out of sync? Userid is an auto-increment field and can easily get out of whack. User A regs at your board and user B regs at your friends board at the exact same moment and they both get userid 40. User A then get 41 on your friends board and User B gets 41 on your board. You now see they are different. vB operates off of the $bbuserid so it would be important for them to match. I hope I have scared you enough to not try this. I would suggest you just make (or ask) for a hack that would modify only one of your boards (yours or your friends) to use the other boards user database. You would have no synchronization problems with that outcome.
yes you have scared me enough :D
So is it possible to have not sharing a database, but to register for another board? if it doesn't sync t wouldn;t be such a problem, because the user would still be reged on one board, but not another
Thanks for you help, and I'm sorry if I'm not understanding what you r trying to say :(
but if I did, is ther a safe way to do this? Waht would you recommend?
Originally posted by conan
I'm sorry I think I know what you mean know, but how would I reference one database frmo another board? Where would I have to change?
You would edit config.php. Duplicate the connection settings but change them to match the server that is going to hold the user table and assign the connection a different name other than $DB_site (perhaps $DB_user)
Say your forum is the one we are going to use for the user table. We change nothing on yours. You give your friend your database settings, he does what I said above. He then has to edit every php file that uses the user table and change the lines that insert/select/update/delete the user table from $DB_site to $DB_user
Would this be sufficient for what you want?
Your database would also need to have permission to allow your friend's server to connect. It may already allow connections from anyone but you would have to ask your admin, or just try and see if it works.
You then lock your friend into having to make these changes every time he upgrades.
That would be great, thansk a lot for you time, and fast replies!
ok here's what I'm gonna try to accomplish with a hack I have in mind!
- I will add a check box on the bottom of the registration form giving the user the option to register for another board as well, by default the box will be checked.
- Then after the user receives a successful status registering to your board, it would redirect to the registration form on that other board.
- The registration form on that other board, would be already filled with the previous information the user input on your board (this would be accomplished by using a JavaScript or something similar)
- Then the user submits the second form, and waits for a registration confirmation, fomr that other board, and if course if that nick already exists it would return an VBB message, asking the user to try another nick.
I think this would be a very useful hack, I'm willing to give this a try, but I'm a newbie with both php and VBB, so any help will be appreciated, also if anyone feels like making this hack alone, please do it, I don't care if I had the idea or not, I don't want any credit. The hack working would be enough for me ;)
Also please let me know what you think of this idea!
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.