Firefox PHP

Point forum to exisitng database (so members do not signup twice)

Posted by xpok3rkingx 
Point forum to exisitng database (so members do not signup twice)
November 07, 2010 09:57AM
Wow sweet phorum!!! is there a way i can point this to exisitng membership tables? so members do not sign up twice
Re: Point forum to exisitng database (so members do not signup twice)
November 07, 2010 02:29PM
That is less simple than you might think. You will always need a Phorum user in Phorum's users table. The Phorum user is needed for things like storing settings and keeping track of new message flags.

What kind of integration did you have in mind? Normally, admins are looking for a singe sign on solution. That makes it possible for your users to login to your main site, automatically logging them into the Phorum pages as well. That is different from what you request. Your request implies that users would have to login to both your main site and Phorum, since there is only user data sharing. For this kind of integration, there are various options.

a) you could add code to the main site user registration code, to automatically create a Phorum user record.

b) you could write a module that implements the user_authenticate hook. The hook code could check the username + password against the main user data and create (or sync) the Phorum user data on-the-fly.

There are loads of options and integration can be done in many ways. One thing that all solutions share, is that you need to write some code to handle the specifics for your situation. If you can explain some more about what you are after exactly, we might be able to give you some more specific pointers for modules or code to look at.


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Point forum to exisitng database (so members do not signup twice)
November 08, 2010 04:51AM
Ok man , i think i understand this , i looked at the code in there , and where it says for example // Check if a Phorum user exists for the active username.
// If the user does not exist. Create a new user.
$user_id = phorum_api_user_search("username", $active_user_data['username']);
if (!$user_id)
{



Replace that path with my membership system? replace all your member data with mine right?



Edited 1 time(s). Last edit at 11/08/2010 04:56AM by Maurice Makaay.
Re: Point forum to exisitng database (so members do not signup twice)
November 08, 2010 05:01AM
Please, as requested, stick with your support own thread for further support.

In the piece of code that you quoted in your question, there is not a single byte that needs changing. Therefore, if you are referring to this piece of code with "replace all your member data with mine right", then the answer is "no, wrong"
You also talk about "that path". There is no path in the quoted code. I am not sure what you are referring to here.

One more time, I request you: please provide some more technical information about the membership code / session management that you are using for your site, then we might be able to help you. Without such info, asking for confirmation on random chops of code isn't going to get you any further. Anyway, not on my behalf.


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Point forum to exisitng database (so members do not signup twice)
November 08, 2010 05:25AM
well ill tell you this is my membership system www.webintersect.com (goto downloads version 1.33)s the version i am using thats my membership system , right now (but what youd see on the site is the membership system but the source files are in the downloads)im using the mod_inherit_authentication_from_session.php to point to my membership system i dont know how else to explain the membership system its made from scratch



Edited 1 time(s). Last edit at 11/08/2010 05:28AM by xpok3rkingx.
Re: Point forum to exisitng database (so members do not signup twice)
November 08, 2010 05:35AM
Okay, tell me: are you a programmer or not? My impression is that you are not, but you say that the membership system is made from scratch. Did you create it from scratch or did you just install it?

If you do not understand the basic ideas behind the code in the file mod_inherit_authentication_from_session.php, then I doubt that you are savvy enough to handle the integration with webintersect on your own. If I am right about it, then you will need to find a (PHP) programmer that can help you with this.

and could you add some interpunction and capitals to your messages because it makes your messages easier to read since now i really need to try hard to find out where your sentences start and end it also is a sign of respect to people when you take the time and effort to create a well formatted message plz


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Re: Point forum to exisitng database (so members do not signup twice)
November 08, 2010 06:32AM
@ xpok3rkingx

i have edited my first message in the other topic.
with very little php knowledge you should get it working now.



Edited 1 time(s). Last edit at 11/08/2010 06:34AM by Terradon.
Re: Point forum to exisitng database (so members do not signup twice)
November 08, 2010 06:39AM
Please note that the PHP file does contain code that is specific to Terradon's user system (e.g. who the admin user is and how the user session is stored in $_SESSION) Therefore, this is not a drop-in recipe, it still needs some coding on your behalf.

Thanks for writing down your steps Terradon!


Maurice Makaay
Phorum Development Team
my blog linkedin profile secret sauce
Sorry, only registered users may post in this forum.

Click here to login