Last post Dec 11, 2018 10:29 AM by yogyogi
Dec 11, 2018 05:23 AM|Kamayani|LINK
After user has registered / email notification after clicking link, how to redirect user to his account without asking to login.
Your help is very much appreciated.
Dec 11, 2018 10:29 AM|yogyogi|LINK
You can do these things:
<a href="http://www.yourwebsite.com/login/?guid=0f8fad5b-d9cb-469f-a165-70867728950e">Login to your account</a>
So when the user clicks the link he reaches the website's login page. In that login page you extract the guid value from query string. Then you match the guid with the guid column of the table. So you get the User Id of the person.
Now you know which user has clicked the link and you do the automatic login.
Some website also adds the expiry time of the guid. For this they add a new
ExpiryTime column on the table. And this helps them to prevent users to use the link for login after the exprity time has reached.
I hope I am clear in my explanation.