hasjem Posted May 5, 2010 Share Posted May 5, 2010 when people sign up they have to give an emailaddress. I want to send an email to that address with the question to click a link to make sure that emailaddress belongs to the user. how do i do that? thanks lex Quote Link to comment https://forums.phpfreaks.com/topic/200770-how-do-i-send-an-email-with-a-link-to-verify-that-the-email-is-from-the-user/ Share on other sites More sharing options...
Muddy_Funster Posted May 5, 2010 Share Posted May 5, 2010 For mailing have a look at this http://uk2.php.net/manual/en/function.mail.php What you will want to do is store a hash in the database against the new user, select this hash back out the database (make sure you enclose it in singel quotes) and mail it to the user with the prefix of "http://www.mysite.com/registration.php?hash=" on the address provided by the form. have a registration.php page that uses $_GET['hash'] to run a select against the hash in the database and then flag the user as authorised if they match. You will need to make sure you have columns in your database to store a status flag and the hash. If you have any issues let us know. Quote Link to comment https://forums.phpfreaks.com/topic/200770-how-do-i-send-an-email-with-a-link-to-verify-that-the-email-is-from-the-user/#findComment-1053474 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.