[how?] registration completed by email

Place for questions and answers for all newcomers and new coders. This is a free for all forum, no question is too stupid and to noob.
Post Reply
User avatar
Nerfintas
Posts: 54
Joined: Wed Aug 28, 2013 6:01 pm

[how?] registration completed by email

Post by Nerfintas »

so, we have a simple registration page. how to di it by complete reg by email with unique url?
User avatar
OldRod
Posts: 1320
Joined: Sun Sep 20, 2009 4:26 pm

Re: [how?] registration completed by email

Post by OldRod »

You collect the user's email address during registration. What I would do is generate a unique id key, maybe by hashing their username along with the date or something. Store this hash in the database along with their username. Then generate a url that includes their username and this id key (http://www.something.com/authenticate.p ... ode=idhash) send them this link in an email.

When they click on the link, you get the username and hash from the url on your authenticate page, look up the username in your database and compare the id key to the one you stored earlier. Voila! :)
User avatar
vitinho444
Posts: 2819
Joined: Mon Mar 21, 2011 4:54 pm

Re: [how?] registration completed by email

Post by vitinho444 »

that's a really good system oldrod ;)
My Company Website: http://www.oryzhon.com

Skype: vpegas1234
User avatar
Nerfintas
Posts: 54
Joined: Wed Aug 28, 2013 6:01 pm

Re: [how?] registration completed by email

Post by Nerfintas »

OldRod wrote:You collect the user's email address during registration. What I would do is generate a unique id key, maybe by hashing their username along with the date or something. Store this hash in the database along with their username. Then generate a url that includes their username and this id key (http://www.something.com/authenticate.p ... ode=idhash) send them this link in an email.

When they click on the link, you get the username and hash from the url on your authenticate page, look up the username in your database and compare the id key to the one you stored earlier. Voila! :)
sounds good but how to insert that system? i dont get it still :) at least my english not verry good
User avatar
OldRod
Posts: 1320
Joined: Sun Sep 20, 2009 4:26 pm

Re: [how?] registration completed by email

Post by OldRod »

Check out these videos:

http://www.youtube.com/watch?v=erFZWX9a ... 77783367C7

There is that one, plus 2 or 3 more in the same series where he details how to do this.

These videos are part of a larger series on building a login/registration system in PHP, which is a good series to watch, but those 3 or 4 videos detail the email registration part.
User avatar
Nerfintas
Posts: 54
Joined: Wed Aug 28, 2013 6:01 pm

Re: [how?] registration completed by email

Post by Nerfintas »

OldRod wrote:Check out these videos:

http://www.youtube.com/watch?v=erFZWX9a ... 77783367C7

There is that one, plus 2 or 3 more in the same series where he details how to do this.

These videos are part of a larger series on building a login/registration system in PHP, which is a good series to watch, but those 3 or 4 videos detail the email registration part.
thanks :)
Post Reply

Return to “Beginner Help and Support”