How To Create A Forgotten Password System In PHP | Password Recovery By Email In PHP | PHP Tutorial

In this PHP tutorial you will learn how to create a forgotten password system in PHP. To follow this tutorial you only need to have basic knowledge in PHP and a login system ready. We will be creating our password recovery system using PHP tokens which is a method we use to authenticate the correct users who try to reset their password.


(00:00:00): Introduction
(00:00:31): Ways to make a Password Recovery system
(00:03:51): What is a token?
(00:04:50): Why PHP e-mails…

, , , , , , , ,

47 thoughts on “How To Create A Forgotten Password System In PHP | Password Recovery By Email In PHP | PHP Tutorial

  1. Hello Mr.Daniel,you will forgive me am kinda off topic but i would like to get some help from you or any one who sees this comment.

    i have a link where i attach or pass in dynamic values from php.

    it looks like this:(example)

    <a href="details.php?id=<?php echo $row['id']; ?>&title=<?php echo $row['title']; ?>">
    <?php echo $row['title']; ?>

    When the user clicks the title link,it displays this in the url.(Please don't click the link,its just for example)

    i want it to display like this(smart url).

    if possible, a tutorial will be better.
    Thanks, oston..

  2. Hi!
    I followed your login sys tutorial in PHP and copied your code exactly except that mine doesn't require an email, however, when I run it the URL bar is empty and nothing happens. I check my DB and don't see any results, my root folder is configured in the right way and the main is referred to. I'm extremely confused and I would really appreciate some help, thank you!

  3. Thanks for the video. I created my forgot password system about 6 months before. It uses OTP system and it’s working awesome. Still awesome video. I learned a bit more

  4. I love your tutorial. Actually, I built an entire system just by watching your tutorials for my university project. It would be great if you could teach us some frameworks like Angular and Node. Keep up the good work!

  5. Thanks, I learn from your tutorials all the time. Just have a question. Maybe I'm wrong, but don't you want first to try and delete the password-reset-token from the database BEFORE update the user's password? because otherwise if you first update the password and then the SQL fail to delete the token, you now have a user that can login AND has a reset token in the db. What do you think?

  6. You did this tutorial for me bro,, i have a reporting system that i developed using your tutorials, everything else works but i was stuck trying to figure out how to make reset password,,, u a freaking freaking genius,,

  7. 37:29 Two things:
    – Instead of echoing the message and using exit(); after you should just use die("insert message here");
    – After the if statement, you could just remove the else statement due the command inside the if statement, because if there is infact an error it will stop the script thus being useless to make an else and just continue the script normally

    Besides that loved it!

  8. Always helping me improve my programing luangues. I also would like to know how does cryptocurrency in signup and login create by addresses. thanks so mach, your videos are amazing.

Leave a Reply

Your email address will not be published. Required fields are marked *