name alert




JavaScript Source Code 3000: Messages: Name Alert

































Name Alert








JavaScript can personally great all the visitors to your web page! When they enter, they are asked their name, and then they are greeted! Ah.... The wonders of JavaScript.














JavaScript Source Code 3000: Messages: Name Alert
Simply click inside the window below, use your cursor to highlight the script, and copy (type Control-c or Apple-c) the script into a new file in your text editor (such as NotePad or SimpleText) and save (Control-s or Apple-s). The script is yours!




    





<!-- THREE STEPS TO INSTALL NAME ALERT:

1. Paste the coding into the HEAD of your HTML document
2. Copy the onLoad event handler into the BODY tag
3. Add the last code into the BODY of your HTML document -->

<!-- STEP ONE: Copy this code into the HEAD of your HTML document -->

<HEAD>

<SCRIPT LANGUAGE="JavaScript">

<! >
<! >

<!-- Begin
function testIt() {
Response = "";
while ((Response == "") || (Response == "")){
Response=prompt ("Who are you?", "");
}
if (Response != null)
alert ("Hello, " + Response + "!");
}
// End -->
</SCRIPT>

<!-- STEP TWO: Add this onLoad event handler into the BODY tag -->

<BODY onLoad="testIt()">

<!-- STEP THREE: Put this code into the BODY of your HTML document -->

<CENTER>
<FORM>
<INPUT TYPE="button" NAME="button1" VALUE="Hello! Click Here!" onClick="testIt()">
</FORM>
</CENTER>



<!-- Script Size: 1.00 KB -->











Wyszukiwarka

Podobne podstrony:
function fdf next field name
name based
alert button
function session name
Death Note 2 The Last Name [2006] [XVID] [ENG Subbed] [SARS]
alert
Sharash Derive Name from Tablet

więcej podobnych podstron