激情燃烧的木炭

微笑生活,努力工作,让我们做得更好!

📚 学习

Javascript 简单弹窗相关操作类

📚 学习

this. this. this. this. this. this. this. this. this. } this. this. this. this.this. this. this. this. this. this. } this.frmDialog) this.title) { this.frm) this.content) { this.appendChild(this.appendChild(this.appendChild(this.appendChild(this.

来源: 编辑: 关键词:this style opts

Javascript 动态加载脚本(JS)资源(.css .less)文件等

📚 学习

file. file. file. file. file. file. file. file. file. file. file. file. if (!onload = file.onload = file.appendChild(file);onload = file.onload = file.appendChild(file); i if (this. try { file. try { file.js") { file = document.

来源: 编辑: 关键词:file if url

Javascript 获取地址的绝对路径

📚 学习

var p = '';/') >= 0) { var pathList = path. var pathList = path. var del = 0; if (path. for (var i = 0; for (var j = i - 1; } if (path. var ps = []; var pathLen = pathList. var pathLen = pathList. } else if (path. } else if (path.

来源: 编辑: 关键词:var path host

验证 jQuery 是否完全加载?

📚 学习

scr. scr. scr.appendChild(scr);jQuery) { var scr = document.onload=function(){ fun(); }} else { fun();}function fun(){ console. document.org/latest/jquery.log($())}getElementsByTagName('head')[0].type="text/javascript";createElement('script');

来源: 编辑: 关键词:scr fun function

Javascript 中全局错误捕捉

📚 学习

error.error && ! if (! if (f === f.window. } ext = ext. msg = ext; } //没有URL不上报! m += FF. m += FF. m += FF.onerror = function(msg, url, line, col, error) { if (!= "Script error.上报也不知道错误 // if (msg ! var f = arguments.event && window.

来源: 编辑: 关键词:error if window

jQuery 中 ready 的实现

📚 学习

document.addEventListener) { document.attachEvent) { document.call(document);call(document); } else if (document. //当获得事件时,要运行的函数 var ready = false; } //事件处理函数完整执行,切换ready状态, 并移除所有函数 ready = true; i funcs[i]. } //为接收到的任何事件注册处理程序 if (document.

来源: 编辑: 关键词:函数 document 事件