SolveSpace Logo SOLVESPACE -- parametric 2d/3d CAD
Examples
Tutorials
Features
Download
Reference
Technology
Library
Forum
Contact

School Management System Project With Source Code In Php Online

// marksheet.php
$student_id = $_GET['student_id'];
$exam = $_GET['exam_type'];

$sql = "SELECT subjects.name, marks.marks_obtained, marks.max_marks FROM marks JOIN subjects ON marks.subject_id = subjects.id WHERE marks.student_id = $student_id AND marks.exam_type='$exam'";

$result = mysqli_query($conn, $sql); $total_obtained = 0; $total_max = 0;

while($row = mysqli_fetch_assoc($result)) echo $row['name'] . ": " . $row['marks_obtained'] . "/" . $row['max_marks'] . "<br>"; $total_obtained += $row['marks_obtained']; $total_max += $row['max_marks']; $percentage = ($total_obtained / $total_max) * 100; echo "<strong>Total: $total_obtained/$total_max (" . round($percentage,2) . "%)</strong>";

school-management-system/
│
├── assets/
│   ├── css/ (custom styles, Bootstrap)
│   ├── js/  (custom JS, jQuery)
│   └── images/
│
├── config/
│   └── database.php (DB connection)
│
├── includes/
│   ├── header.php
│   ├── footer.php
│   ├── sidebar.php
│   └── auth.php (session validation)
│
├── modules/
│   ├── admin/
│   │   ├── dashboard.php
│   │   ├── manage_students.php
│   │   ├── manage_teachers.php
│   │   └── ...
│   ├── teacher/
│   │   ├── attendance.php
│   │   ├── marks_entry.php
│   │   └── ...
│   ├── student/
│   │   ├── view_attendance.php
│   │   ├── view_results.php
│   │   └── ...
│   └── parent/
│       ├── child_attendance.php
│       └── fee_status.php
│
├── login.php
├── logout.php
├── index.php (redirects to login or dashboard)
└── README.md

Once the basic system works, consider adding:


Want to make your system stand out? Try these:


The School Management System (SMS) is a web-based application built in PHP and MySQL designed to automate the daily operations of a school. It manages students, teachers, classes, attendance, fees, exams, and grades. This system eliminates paperwork, reduces manual errors, and provides a centralized dashboard for administrators, teachers, students, and parents. school management system project with source code in php

Key benefits:


| Component | Technology | |----------------|----------------------------------| | Backend | PHP 7.4+ (Procedural or OOP) | | Database | MySQL 5.7+ | | Frontend | HTML5, CSS3, Bootstrap 5 | | JavaScript | jQuery, AJAX (optional) | | Server | Apache (XAMPP/WAMP/LAMP) |


School Management System (PHP & MySQL)

<?php
session_start();
require_once 'config/database.php';

if ($_SERVER['REQUEST_METHOD'] == 'POST') $username = trim($_POST['username']); $password = $_POST['password'];

$stmt = $pdo->prepare("SELECT * FROM users WHERE username = ?");
$stmt->execute([$username]);
$user = $stmt->fetch();
if ($user && password_verify($password, $user['password'])) 
    $_SESSION['user_id'] = $user['user_id'];
    $_SESSION['role'] = $user['role'];
    $_SESSION['username'] = $user['username'];
    header("Location: modules/" . $user['role'] . "/dashboard.php");
    exit();
 else 
    $error = "Invalid username or password.";

?> <!-- HTML Form here -->

© 2008-2022 SolveSpace contributors. Most recent update June 2 2022.