|
And here is my favorite item, a game of Hangman in JavaScript.
Click on this button to play the game.
Explaining this thing is too much of a drag, so I'll leave it out. If you are interested in the code you can always do a View source :-) If you are using MSIE on Windows 95 and if MSIE opens up maximized by default, then you may notice that the game window is not resizable. To solve it, just click the restore button on the title bar. This is an MSIE bug. In Netscape, the buttons are not aligned. I don't think it is possible to have buttons of equal size in Netscape, but if I'm wrong, you are welcome to correct me. The only solution seems to be to use hyper-linked images instead of buttons. Maybe I'll do it...
Another problem is that, after finishing a word when you
move on to the next one, the last buton you pressed will
still have square brackets around indicating (wrongly)
that it has been pressed. The cause is that the If you would like to put a Hangman button on your web page, use the following code. Although I have used 6 lines of code, you should edit it so that all 4 lines between the <FORM> and </FORM> tags come on a single line without any line breaks in between. (Or at the least , make sure that strings between double quotes don't have any line breaks in between.) <FORM> <INPUT TYPE=BUTTON VALUE="HangMan" onClick = "window.open( 'http://www.oocities.org/SiliconValley/Park/2554/hangman.html', 'hman','status=yes,resizable=yes,height=265,width=545');"> </FORM> If you want the source code, you can download hangman.zip. Be sure to read the readme.txt after unzipping. |