Alerts
- The alert dialog box displays the message given to it.
- Only an OK response is allowed to the user.
- The script and HTML document halts execution until the user chooses
the OK button.
- The phrase "JavaScript Alert" is included in the dialog box
to let the user know what caused the alert.
Some uses
- Insufficient information provided in a form.
- Incorrect data entered
- Invalid result
- Service that is unavailable
Add the following line to your program at the start.
alert("Just Learning JavaScript, Please Be Patient");
Run the program.
Back