jquery弹出层类代码分享_Javascript教程-查字典教程网
jquery弹出层类代码分享
jquery弹出层类代码分享
发布时间:2016-12-30 来源:查字典编辑
摘要:复制代码代码如下:vart9=newPopupLayer({trigger:"#ele9",popupBlk:"#blk9",closeBt...

复制代码 代码如下:

var t9 = new PopupLayer({trigger:"#ele9",popupBlk:"#blk9",closeBtn:"#close9",

useOverlay:true,useFx:true,offsets:{x:0,y:-41}});

t9.doEffects = function(way){

if(way == "open"){

this.popupLayer.css({opacity:0.3}).show(400,function(){

this.popupLayer.animate({

left:($(document).width() - this.popupLayer.width())/2,

top:(document.documentElement.clientHeight -

this.popupLayer.height())/2 + $(document).scrollTop(),

opacity:0.8

},1000,function(){this.popupLayer.css("opacity",1)}.binding(this));

}.binding(this));

}

else{

this.popupLayer.animate({

left:this.trigger.offset().left,

top:this.trigger.offset().top,

opacity:0.1

},{duration:500,complete:function(){

this.popupLayer.css("opacity",1);this.popupLayer.hide()}.binding(this)});

}

}

相关阅读
推荐文章
猜你喜欢
附近的人在看
推荐阅读
拓展阅读
  • 大家都在看
  • 小编推荐
  • 猜你喜欢
  • 最新Javascript教程学习
    热门Javascript教程学习
    编程开发子分类