User ID

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
SilverMist
Forum Commoner
Posts: 65
Joined: Tue Mar 02, 2004 2:06 pm
Location: Canada
Contact:

User ID

Post by SilverMist »

Hey! When people join an online community, how do they get their ID to show up? I have my database set on ID, INT, auto_increment already. Now what do I do?
User avatar
tim
DevNet Resident
Posts: 1165
Joined: Thu Feb 12, 2004 7:19 pm
Location: ohio

Post by tim »

your already on the right path by having a auto_inc field to assign a different number to each new coming row of data (each new user)

I suggest your next step is to look into cookies, when they sign-up, plant a cookie on their computer to store the username.

check out: http://us4.php.net/manual/en/function.setcookie.php for info.

you can also use sessions, or a combo of both =]
Post Reply