JavaScript Reference/Javascript Methods/alert

Материал из Web эксперт
Перейти к: навигация, поиск

"alert()" Example

    
<html>
<body>
<input type="button" onClick="alert("This is an alert window");" value="Click me">
</body>
</html>



"alert()" is applied to

+----------------+--------------------------------------------------------------+
| Applied_To     |window                                                        |
+----------------+--------------------------------------------------------------+



"alert()" Syntax, Parameters and Note

Note:
An alert message in a dialog window.
    
Syntax:
    
window.alert(param1)

Parameters:
    param1   Optional; the message.