Conditional execution (If-then-else statements): see pp. 195-205 of Reed text. Watch your {curly braces}!
Details:
Create a web page that verifies that the user (viewer) is indeed a human (or at least, a VERY intelligent computer program!):
You have seen this before: you are shown an image of some text, but the text is obscured by distortions, blurriness, and/or random-like patterns over the characters
. You are asked to type into an input box the letters and numerals that you see, then click "enter", "return", "submit", etc. The purpose is to make it hard for any automated web crawler to get past this point, as it would require some sophisticated image-processing and character-recognition algorithms to see the actual characters in the image. Heck, it takes ME some time to make sure I get it right! (In my opinion, this task is just at the very edge of the current state of artificial intelligence research.)
TASK 1: CELSIUS->FAHRENHEIT
First, show me that you can work with Javascript. Take
the Temperature Conversion example from our text book (here)
and change it so that it converts Celsius to Fahrenheit (instead
of Fahrenheit to Celsius, which is what it does now).
Show me your code working. (25 points)
TASK 2: HUMAN-DETECTOR
First show the user an image like the one above. (10 pt.s)
Prompt the user for the text in the image (20 pt.s)
If the user gets it right, then show the user a special
message. (10 pt.s)
If the user gets it wrong, show them a different message.
(10 pt.s)
If the user gets it right, make the special message a
mailto: (your email) (5 pt.s)
Make the mailto: as obscure as possible (10 pt.s)
Good style (indentation, comments, etc) in source code. (10 pt.s)
Grading: Total 100 pt.s. The usual grading scale (i.e., 90 to 100 pt.s is an A, 80 to 89 pt.s is a B, etc.)
Turn-in Procedure: Put your web pages on the web (use your myweb.nmu.edu web site or your own web server account if you have one). Email me the URL for this assignment: (jhorn@nmu.edu).
Keep it "secret"! Use an obscure URL.