首页 相关文章 jquery 弹出层实现代码

jquery 弹出层实现代码

经过分析,网上的参考,终于搞定了~~
jQuery插件代码:
代码如下:
jQuery.fn.selectItem = function(targetId) {
var _seft = this;
var targetId = $(targetId);
this.toggle(
function() {
var A_top = $(this).offset().top + $(this).outerHeight(true); // 1
var A_left = $(this).offset().left;
targetId.bgiframe();
targetId.show().css({ "position": "absolute", "top": A_top + "px", "left": A_left + "px" });
}
, function() {
targetId.hide();
}
);
targetId.find("#selectItemClose").click(function() {
targetId...[ 查看全文 ]

2016-02-19 标签:

jquery 弹出层实现代码的相关文章

手机页面
收藏网站 回到头部