03 2021 档案
摘要:function getParam(url){ var x={}; var pattern=/(\w+)=(\w+)/ig; url.replace(pattern, function(a,b,c){ x[b]=c; }); console.log(x["name"]); //测试用 name }
阅读全文
摘要:要求:一个once函数,使传入的函数只执行一次 代码: function once(fun){ var tag=true; return function(){ if(tag){ tag=false; fun(); } } } 测试: function gou(){ document.write("
阅读全文
摘要:直接上代码 div { width:0px; height:0px; border-top:0 solid red; border-right:300px solid transparent; border-bottom:300px solid blue; border-left:300px sol
阅读全文

浙公网安备 33010602011771号