PDA

View Full Version : Automatically add forum user


beltane
07-18-2006, 05:58 AM
Hi there,

I'm wanting to use vbulletin for an existing site I have, with a pre-existing member login. I want to create a new forum registration with the same username/password when someone joins the main site, but after that the accounts can be seperate. From my understanding, this could be done by an SQL insert statement in my existing registration, but I'm not sure if this is possible with vB? I can get the password in plain text using $_POST.

I'm keen to get started and I've read a few posts on here from my search, but I'm not 100% sure it's possible.

(I also posted this on vbulletin.com, apologies if they're related sites, I'm very new to vB!).

Chris M
07-18-2006, 07:11 AM
This would be possible with vBulletin yes :)

Obviously the more in-depth you go about a single registration form and whether you wish to have a single sign-on system, determines how you do this :)

People round here are very helpful and will be willing to assist you if you come accross any problems or have queries about how data can be used in a single sign-on system :)

Chris

beltane
07-18-2006, 07:25 AM
Thanks for the quick reply Chris! All I'm wanting to do is create a new user with the same username and password, both of which I can capture when they submit the user form, everything else can be the default user settings for a new user on vB.

A single login would be a 'nice to have' once I get it under control intially, but for now I don't want a login bridge, or single sign in, just the ability for people who join the main site to be able to login and post on the forums without having to create another account :).

If it can be done fairly painlessly then I'll certainly be buying vB to use, as my time is pretty limited at the moment.

Chris M
07-18-2006, 08:25 AM
In that case it should be fairly easy to do - The only thing that you may need to watch out (I've never attempted this myself with vB 3.5 or 3.6 ;)) for is how the password is stored in vBulletin, as it uses an md5 hash with a unique salt; Looking through how the registration file does it should tell you how that is created but if there are any questions, you are likely to find someone who knows here :)

Chris

beltane
07-18-2006, 11:06 AM
Well I am now the owner of a new vB owned license ...I'm sure I'll be back once I get going!

Marco van Herwaarden
07-18-2006, 11:08 AM
Congratulations on your purchase and welcome to the community.

Chris M
07-18-2006, 11:47 AM
Welcome to the community :)

Chris

y2ksw
07-28-2006, 11:43 AM
Registering a user from another web application is not very easy.

Basically it needs the following steps:

Get current server date and time
Check if user already exists (exit if yes; prevents from overwriting a user who first registered to the forum, then to your application)
Add user to forum and a specific usergroup ID:
Hash password if length <> 32 characters (assuming a cleartext password), and hashes to MD5 with salt
Insert the user record
Set the minimum reputation level
Insert custom user fields
Insert record into password history
Build user statistics
Additionally it may need the addition of an avatar, a personal user title and something alike.

Hope this helps