Jump to content

making a register script


Dangmnx

Recommended Posts

Why not write one yourself?

 

Make a table (called "users") to hold information like name, email, password hash, level (eg. 0=not activated, 1=user, 2=moderator, 3=admin), banned (enum['yes','no']) and any other information you need to store. Have the userid being the primary key.

 

Upon registration (register.php) check if the email is already used and not allow it again. Might want to do the same for the username.

 

When they register email them a link to activate the account. This can be in a separate table (called "activations") where you store their userid and the activation key).

 

Another script gets called when they click the link in their email (activate.php) checks the activation key & userid in the URL against the activations table and a match updates the level to 1 - user. If either didn't match they get told something didn't match and leave level as 0.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.