Computer-Based Testing System
A Structured Web Application for Digital Assessment
Project Overview
The Computer-Based Testing System is a web application that digitalises the full examination workflow — from exam creation and question management through to participant sessions, automatic scoring, and result storage. It replaces manual paper-based exam administration with a structured, role-controlled digital process.
The system was designed for institutions or training environments that need a reliable, repeatable digital assessment workflow without reliance on commercial LMS platforms.
The Problem
Manual exam administration creates several recurring problems:
- Exam papers must be printed, distributed, collected, and manually scored — a time-intensive process with room for error at each step.
- Tracking which participants have completed which exams is difficult to do consistently at scale.
- Storing and querying historical results for reporting requires manual data entry.
- Preventing unauthorized access — participants seeing each other's answers, or accessing content before their session — is not reliably enforceable with paper.
The goal was to solve all of these with a single web application that enforces consistent workflows for every role involved.
Role Structure
The system has three distinct roles, each with specific capabilities:
Administrator
- Create and manage exams
- Manage question banks
- Register participants
- View all results and reports
- Control exam availability
Examiner
- Monitor active exam sessions
- View participant progress
- Access exam results
Participant
- Access assigned exams only
- Take timed exam sessions
- View own results post-submission
System Architecture
Exam Session Design
Exam timing is enforced server-side. When a participant starts a session, the start time is recorded in the database. All time calculations are performed server-side based on this stored timestamp — not on the participant's browser clock. This prevents client-side manipulation of the timer.
When the session time expires, the system automatically submits and scores any answers recorded up to that point, even if the participant has not manually submitted. Auto-submission is handled by a server check on every answer save request.
Questions are served one at a time or as a full set depending on the exam configuration. Answers are stored to the database as the participant progresses rather than only on final submission — this protects against data loss from unexpected browser closures or network interruptions.
Scoring Engine
Scoring is automatic for objective question types (multiple choice, true/false). At session end, stored answers are compared against the correct answers in the question table. The score, percentage, and pass/fail status are calculated and written to the results table.
| Question Type | Scoring Method | Status |
|---|---|---|
| Multiple Choice (Single) | Exact match | Implemented |
| True / False | Exact match | Implemented |
| Multiple Choice (Multi) | Set comparison | Implemented |
| Short Answer | Manual review | Planned |
| Essay | Manual review | Not in scope |
Access Control
Every request to a protected route is validated against the user's session role. Role checks are performed at the backend, not the frontend — hiding a UI button does not grant access if the underlying endpoint is called directly.
Participants can only access exams they have been explicitly assigned to. Attempting to access an exam by direct URL without an active assignment returns an access denied response.
Stack Details
| Layer | Technology | Purpose |
|---|---|---|
| Frontend | HTML, CSS, JavaScript | All three role interfaces |
| Backend | PHP | Application logic, session, auth, scoring |
| Database | MySQL | All persistent data |
| Timer | PHP + JS | Server-authoritative with client display |
Current Status
Completed. The system implements the full exam lifecycle: creation, question management, participant assignment, timed sessions, automatic scoring, and result storage. It has been tested for the core workflows and access control scenarios described above.