浏览器中的系统三个弹窗

1.提示框

特点:提示信息,没有交互。只有一个确定按钮

用法:alert(‘hell word’)

2.对话框

特点:跟浏览器进行对话,有一个输入框,两个按钮,确定按钮,关闭按钮

         返回值是: 用户输入的内容

用法:prompt(‘hello world’)

 

3.确认框

特点:确定按钮,和取消按钮。返回true或者false

用法:confirm('你确定要删除这条数据么?');

 

猜你喜欢

转载自blog.csdn.net/zyf19971112/article/details/81941421