This is a simple documentation of my project, developed to transform manual school systems into a web-based system.
By no means is this project perfect, but it fulfills many requirements of schools.
You can download the project from the GitHub repository using the git clone command. Here's how
- Open your terminal or command prompt.
- Navigate to the directory where you want to clone the repository.
- Run the following command:
git clone https://github.com/Saboor-Hamedi/student-management-system.git
. If you haven't already installed Composer, you can download and install it from getcomposer.org. . Follow the installation instructions for your operating system.
. In your project directory, create a file named composer.json if you don't already have one.
. Inside composer.json, add the following lines to configure autoloading with PSR-4:
{
"autoload": {
"psr-4": {
"Thesis\\": "App/"
}
}
}
This project is built using PHP and MariaDB as its database to store data. Object-oriented programming (OOP) concepts have been utilized to reduce redundancy and enhance functionality.
The project includes a clean Auth
class responsible for controlling authenticated users. Currently, there are four different user types in the database: admin, teachers, students, and parents. They are denoted as follows:
- admin: 0
- student: 1
- teachers: 2
- parents: 3
You can add additional user types as needed.
To control access to certain pages based on user roles, follow these steps:
- Visit
config/Auth.php
for more details. - Inside the page you want to restrict access to, e.g.,
admin.php
, callAuth::authenticate([0])
at the top of the page. - To allow access for multiple user roles, include their roles in the
authenticate
method, e.g.,Auth::authenticate([0,1,2,3])
.