Simple Realtime Quiz System using PHP/MySQL with Source Code

Language

Project: Simple Realtime Quiz System using PHP/MySQL

About The Project

The Simple Realtime Quiz System is a PHP/MySQL project that will help teachers for online classes to provide a quiz or quizzes to his/her students on his/her control. This simple project help to connect students answer sheet to their teacher. Talking about the real-time feature of this quiz system will provide the quiz code to his/her student so the student can join the quiz as a participant by the control of their teacher. After that, if the students are connected to the quiz, the teacher will start the quiz and this can be done by the teacher with a single click on the Start Quiz button, which will automatically send the question to all connected student/participants one by one. Each questions intervals is up to the teacher if how long he/she will proceed with to next question, which means the student can change their selected options if they want until the teacher will control the quiz to proceed to the next question. While the students are trying to answer the question, in the teachers' view, he/she can monitor the numbers of participants who choose each question option in realtime. By this feature, the teacher will know immediately the number of students who answered the question right or wrong. When the quiz will meet to the last question next button will be automatically changed into a finish quiz button for the teachers' view, and by clicking this button the students will be redirected to the result of their quiz with their score, and student/participant can review also the part/question that they answered right and wrong, and for the teacher, he/she will be redirected to the quiz management page whereas all option to create, edit and delete question will disappear and change to the quiz summary result of the students who participated. The teacher can also check the answer sheet of each student and print the students' quiz records.

System Pages

  • Login Page
    • The page where the system users will enter their system credentials to access the realtime quiz system.
  • Home Page
    • The page where the system users will be redirected by default after logging into the system.
  • Quiz List Page
    • The page where the admin and teacher user can manage the quiz list. The admin can manage this system but the quiz will be assigned to a teacher.
  • Quiz Management Page
    • The page where can teachers manage the questions of the selected quiz.
  • Quiz Answer Sheet Page
    • The page where the student will be redirected when joining a quiz. This is the page where they answer each question of the quiz with the control of the teacher.
  • Quiz Monitoring Page
    • The page where the teacher controls the interval of each question of the quiz and also where they can monitor the answer and the participants who are connected to the quiz.
  • History Page
    • This page is only for the student's side. This page where all the taken quizzes of the student are listed.
  • Users Page
    • The page where all the system users are listed only be managed by the admin.

How to run

  1. Download the source code and extract the zip file.

  2. Download or set up any local web server that runs PHP script.

  3. Make sure uncomment the "extension=sockets" line in your php.ini file.

  4. Run the php-socket.php file in your command line or terminal. [ php php-socket.php ]

  5. Open the web-server database and create a new database name it realtime_quiz_db.

  6. Import the SQL file located in the database folder of the source code.

  7. Copy and paste the source code to the location where your local web server accessing your local projects. Example for XAMPP('C:\xampp\htdocs')

  8. Open a web browser and browse the project. E.g [http://localhost/realtime-quiz-system-using-php]

Default Admin Access

Username: admin

Password: admin123

There it is, the realtime quiz system is ready to use.

I hope this simple realtime quiz system will help you with what you are looking for. Feel free to download and modify the source code.

Explore more on this website for more source codes and tutorials.
Enjoy!

Note: Due to the size or complexity of this submission, the author has submitted it as a .zip file to shorten your download time. After downloading it, you will need a program like Winzip to decompress it.

Virus note: All files are scanned once-a-day by SourceCodester.com for viruses, but new viruses come out every day, so no prevention program can catch 100% of them.

FOR YOUR OWN SAFETY, PLEASE:

1. Re-scan downloaded files using your personal virus checker before using it.
2. NEVER, EVER run compiled files (.exe's, .ocx's, .dll's etc.)--only run source code.

Comments

Submitted byikansasa (not verified)on Thu, 12/17/2020 - 01:01

how i can make this code to mobile app ?
Submitted byFollow my page (not verified)on Wed, 10/18/2023 - 20:27

In reply to by ikansasa (not verified)

Follow me on Instagram and Twitter account is not working and I am not able to understand the problem is not a problem with the post of the day.
Submitted byxarilaos (not verified)on Wed, 01/20/2021 - 03:38

"Run the php-socket.php file in your command line or terminal." Can you explain this step? Do i expect an output message?
Submitted byAnonymous (not verified)on Wed, 06/01/2022 - 21:45

In reply to by xarilaos (not verified)

Good question... it's running on my end... still waining for some kind of input, it seems...
Submitted byAnonymous (not verified)on Wed, 06/01/2022 - 21:50

I get username or password incorrect... when I dehash the md5 hash in the db, it says admin123, so it should be ok... also jsmith123 doesn't work :(
Submitted byYAO FRANCK (not verified)on Sat, 03/30/2024 - 10:19

In reply to by Anonymous (not verified)

I can not connect. same with admin and admin123

Add new comment