Reputation: 5
I have to develop a online quiz with questions spanning over multiple pages. I have two pool of questions. The pool has to be chosen at random. Once the pool is chosen, the questions have to be displayed in random order to the user. Its a one word answer quiz. I'm planning to use MySQL,apache and PHP to achieve this since I'm new to webapp and they seem easy to learn. Can you please help me with the following things?
Upvotes: 0
Views: 1556
Reputation: 11
You are going to need to store the questions in an array in the session. A session can be restored, I typical bypass the built in session handler and use my own to store objects in the database.
To display one question per page use jquery to show and hide divs. You can then submit the answer via ajax if necessary or wait until all questions have been answered.
If you need to randomize a set of questions use shuffle
Upvotes: 1
Reputation: 4364
LIMIT 1
Yes, sessions are lost when closing the browser. There are two things you can do:
Upvotes: 0