IT 130: The Internet and the Web
Fall 2011

Assignment 6
Conditions and Counters
Due Sunday October 30, Submit before 11:30pm

Overview

You will study and create Web pages that conditionally respond to user input and events as well as count events.

Requirements

Create a Web page for each of the following exercises:

  1. Study the Weather page. Answer the following questions on a Web page:
    1. Trace the code for a temperature of 10 and a humidity of "Dry". Explain what happens in the code. Make sure you present function calls, variable assignments and tested conditions.
    2. Trace the code for a temperature of 50 and a humidity of "Wet". Explain what happens in the code. Make sure you present function calls, variable assignments and tested conditions.
    3. What happens if the Temperature text box is left blank? Why?
    4. How does the function GetDesc obtain the temperature and humidity values?
    5. How does the function GetDesc display the weather description? Explain.
  2. On a separate page, modify the weather page so that it presents weather descriptions that better fit your sensibilities (I'm guessing that you wouldn't consider a picnic if it's 45 degrees and raining). Your new page should provide at least six different weather descriptions.
  3. Study the Dice 2 page. Using a few sentences, explain what happens when the button is pushed. Make sure you present function calls, variable assignments, string concatenations and image presentations.
  4. Modify the dice 2 page so that it has the following qualities (you are strongly encouraged to take an incremental approach):

Optional challenge: add a reset button to your dice page so that counts are reset to zero when the reset button is pushed.

Greater optional challenge: have your page keep track if doubles is rolled three times in a roll. If it is, provide a message of your choosing. Testing this option can be challenge (which you should do).

Once you have completed the Web pages above, create a navigation page that provides links to the exercise pages. Format this page using a suitable list. Add your name to this page.

Deliverables

Using the D2L submission, tell me the URL of your navigation page. Submit your URL by 11:30pm on the due date.