Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/onjoseph/userauth
PHP login and registration system with a CSV database file
https://github.com/onjoseph/userauth
csv-files csv-reading login-system php registration-system
Last synced: 30 days ago
JSON representation
PHP login and registration system with a CSV database file
- Host: GitHub
- URL: https://github.com/onjoseph/userauth
- Owner: ONJoseph
- Created: 2022-10-19T21:55:53.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2022-10-24T07:15:02.000Z (about 2 years ago)
- Last Synced: 2024-10-10T01:30:25.229Z (about 1 month ago)
- Topics: csv-files, csv-reading, login-system, php, registration-system
- Language: HTML
- Homepage: https://ONJoseph.github.io/userAuth/
- Size: 14.6 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# userAuth
## DESCRIPTION
- You have been provided with a github repository with some code skeleton
It has the following
- index.php which is the landing page having links to register and sign in
- dashboard.php is the landing page after successful login
- DIR(FOLDER): assets/style.css
- contains simple page style #DO NOT EDIT
- DIR(FOLDER): html> #DO NOT EDIT
- Login.html which is the login page whose form actions is php/login.php
- Register.html which is register page whose form action is php/register.php
- Resetpassword.html which is the reset password page whose form action is php/reset.php
- DIR(FOLDER): php> #WORK IN THIS FOLDER
- login.php which is the file meant to handle user login (and create user session)
- register.php which is meant to handle user registration
- reset.php which is meant to reset user password
- logout.php which is meant to handle user logout (destroy user session)
## SETUP
- fork this repository to you accounts
- clone the repository to your local pc using `git clone `
- complete the exercise
- onces done, stage your changes using `git add `
- commit your changes using `git commit -m "commit message"
- push you change using `git push`Once you are done, copy the link and paste as your submission.
## TASK:
- With the provided code skeleton, you task is to complete the following files
- registeer.php this file is meant to handle user registration. The form register.html takes in the full names, email and password. In your register.php, you have a skeleton of a function, this function should take the full names, email and password and store the data in storage/users.csv file (this file is like your database). If it was successfully stored, the users should receive the message (“User Successfully registered”)
- login.php. This file is meant to handle user login from the login form, the user inputs email and password from the form, you should check if the email and password provided match that which is in the csv file and if they match, create a session and put the username inside and redirect the user to the dashboard, if it does not match, redirect the user back to the login page
- reset.php this file is meant to update the user password, the data is received from resetpassword.html, it takes in the email and the new password and searches the file, if there is a match for the email, it should update the password field with the new data from the form, else, it should print out “User does not exist”
- logout.php this file is meant to destroy the user existing session and redirect to the login page.