0% found this document useful (0 votes)
2 views3 pages

Individual Assignment

The document outlines an individual assignment that includes questions about PHP functions $_GET and $_POST, as well as session management functions session_start() and session_destroy(). It also describes the tasks for building a user login and registration system, detailing the necessary components such as front-end forms, PHP server-side code, and MySQL database interactions. The assignment emphasizes secure handling of user credentials and data validation.

Uploaded by

yoseftirusew1194
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views3 pages

Individual Assignment

The document outlines an individual assignment that includes questions about PHP functions $_GET and $_POST, as well as session management functions session_start() and session_destroy(). It also describes the tasks for building a user login and registration system, detailing the necessary components such as front-end forms, PHP server-side code, and MySQL database interactions. The assignment emphasizes secure handling of user credentials and data validation.

Uploaded by

yoseftirusew1194
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Individual Assignment (10%)

Write the appropriate brief answers for the following questions


1. Explain the difference between $_GET and $_POST in PHP with an example of when to use
each.
2. What is the difference between the session_start() and session_destroy() functions in PHP? Explain
with examples.

Design

1. Your task is to build a user login system for an online platform. The system should allow users
to log in securely using their credentials. Below are the three components you need to
implement:
a) Front-End Form (HTML):
• Design an HTML login form with fields for username and password.
b) PHP Server-Side Code:
• Write PHP code to Validate input (e.g., check if fields are not empty). Retrieve the user’s
password from the database based on the provided username.
c) Database Interaction (MySQL):
• Create a MySQL database named ‘db’ and a ‘users’ table with columns ‘id,’ ‘username,’
‘email,’ and ‘password’?”

2. Your task is to build a user registration system for an online platform. The system should allow
users to create accounts securely. Below are the three components you need to implement:

a) Front-End Registration Form (HTML):

✓ Design an HTML registration form with fields for name, email address, phone and
password.

b) PHP Server-Side Code:


✓ Write PHP code to validate input (e.g., check if fields are not empty, validate email
format).

✓ Handle any other necessary server-side validation.

c) Database Interaction (MySQL):

✓ Create a MySQL database named ‘db’.

✓ Set up a ‘users’ table with the following columns:

▪ id (auto-incrementing primary key)


▪ name
▪ email address
▪ phone
▪ password

Note: Please ensure that you submit this before the final exam.

You might also like