![](https://img-blog.csdnimg.cn/20201014180756926.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
javascript面向对象编程
persistencequxi
be a better man
展开
-
js重写 alert
查找到了一篇重写alert函数的文章, 记录一下<!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title>JavaScript中alert()方法重写</title> </head> <body> <style type="text/css">转载 2017-12-27 00:40:59 · 340 阅读 · 0 评论 -
js 自定义confirm函数
效果图 <html><head><script>function confirm(obj,url){var odiv=document.createElement('div');var oaa=document.getElementById('aa');odiv.id="odiv";odiv.style.height=80+'px';odiv.style.width=150+'p转载 2017-12-28 01:29:47 · 1913 阅读 · 0 评论 -
window.open 在父页面操纵子页面元素
父页面: Title function showmodelwindow() { var itop = (window.screen.availheight - 510) / 2; //获得窗口的垂直位置; var ileft = (window.screen.availwidth - 650) /原创 2018-01-09 00:11:09 · 3469 阅读 · 0 评论 -
js执行多个onload
先说个坑:DOCTYPE html>"en"> "UTF-8"> Title/title> function opennewwindow() { window.location.href = 'http://www.baidu.com' } >/head> /www.baidu.com"原创 2018-01-20 18:08:06 · 912 阅读 · 0 评论