Midterm Project
Due at start of class, November 10.
Assignment
Using HTML, Javascript, and XML (i.e., AJAX), produce a system for administering multiple-choice quizzes.
Core Specifications
Include all the following features for grades in the range of 80-85:
- A single Web page that displays a question and five options for answers, plus input elements to receive and submit the answer;
- An XML document that encodes a series of questions, options,and correct answers, so that questions may be presented to the user in random sequence;
-
In the Web page, Javascript that:
- Loads the XML document (feel free to use our standard xmlLoader.js);
- Chooses a question, its options, and its correct answer randomly from all question sets defined in the XML document;
- Displays the question and options within elements of the Web page;
- Receives input from the user through a form element;
- Determines if a correct answer has been given;
- Responds (differently) to correct or incorrect answers through some mechanism such as an Alert.
IMPORTANT! The answer process and response MUST NOT RELOAD THE WEB PAGE. It should be possible to answer questions indefinitely without reloading (though of course, questions may eventually recur).
The screenshot at the top of this page shows the required core elements.
Options
For grades above 85, add some or all of the following to the core features given above.
- A running score tally, showing correct answers against total questions or incorrect answers;
- Constrained random selection, such that no question is ever selected twice in succession;
- Variable responses for both right and wrong answers, chosen randomly from String arrays;
- A time limit on answer selection, defaulting to WRONG if the user does not choose within a specified time;
- Calibration of questions by difficulty, such that one or more correct answers increases the difficulty of the succeeding question.
- An end condition that terminates the quiz and takes the user to a summary screen after a certain state is reached (number of questions? number or right or wrong answers? combination of the two?).
Preparation and Submission
Your main Web page must be named index.htm, and must be contained within a folder named midterm. This page must contain a link to a second page named notes.htm. This page must also be saved within the midterm folder. On your notes page, write a sentence or three indicating what features you have included in your project.
You may name your XML file anything you like, provided that name is properly passed to the XML loader in your code. Your XML file must also be placed in the midterm folder.
Save the folder containing all elements of your project (two HTML pages, one XML file) to removable media (thumb drive or CD-ROM), and bring this device to class November 10. At that point, we will walk through moving your work to the Web server on student-iat.ubalt.edu.
Please bring your UB student ID to class on November 10. You will need your student number.
Work must be present on the server in order to be graded. For the moment, however, concentrate on getting your quiz machine to run locally through your browser.
Please test your work only in Mozilla Firefox.
Help
I will not be available during the weeks beginning October 19 and November 2. However, the entirety of class October 27 will be devoted to a Midterm Clinic in which I will attempt to help anyone who is struggling with particular aspects of the project.
Please do your best to plan and organize your work in advance of that meeting. I also encourage you to take part in any study groups the class may choose to form.
|
|