一、 window属性
二、简单的对话框
常用的对话框方法是alert()、confirm()和prompt()
alert() | 向用户显示消息 |
---|---|
confirm() | 要求用户点击OK或cancel按钮来确认或取消某个操作 |
prompt() | 要求用户输入一个字符串 |
alert()
<html>
<head>
<title>页面标题</title>
<script language="javascript">
alert("小范啊啊啊啊");//在页面上弹出
</script>
</head>
</html>
confirm()
<html>
<head>
<title>页面标题</title>
<script language=