87,907
社区成员
发帖
与我相关
我的任务
分享
var creatDiv=function(height){
var div=document.createElement('div');
div.innerHTML='单列模式';
div.style.display='none';
div.style.height=height+'px';
document.body.appendChild(div);
return div
}
var getSingle=(function(fn){
var result;
return function(){
return result||(result=fn.apply(this,arguments));
}
})(creatDiv);
document.getElementById('button').onclick=function(){
var login=getSingle('100');
login.style.display='block'
}