(function(a){a.fn.Qbox=function(d){function e(){c.fadeOut(b.fadespeed,function(){a("#q_box").remove();a("#title_box").remove();a("#close_box").remove();a("#box_bg").remove();c.css("display","none");a("#overlay").css({display:"none"})})}var b=a.extend({title:"",fadespeed:1E3,width:300,height:0,url:"",param:"",minTop:0,minWidth:"",minHeight:""},d);a(this).append('<div id="box_bg"><div id="title_box"></div><div id="close_box"></div><div id="q_box"></div></div>');""!=b.url&&a.ajax({type:"POST",url:b.url, data:b.param,success:function(b){a("#q_box").html(b)}});a("#title_box").html(b.title);var d=a(window),f=document.documentElement;d.scrollTop();var c=a(this);0==b.height?a("#q_box").css("height",c.height()+"px"):a("#q_box").css("height",b.height+"px");a("#q_box").css("width",b.width+"px");""!==b.minHeight&&a("#q_box").css("min-height",b.minHeight+"px").css("height","auto");a("#overlay").css("display","block");a("#overlay").css({height:f.clientHeight});a("#overlay").css({width:d.width()});a("#overlay").css("top", 0);a("#close_box").click(function(){e();return!1});c.css({left:(a(window).width()-c.outerWidth())/2}).css({top:(a(window).height()-c.height())/3});c.fadeIn(b.fadespeed,function(){c.show()})}})(jQuery);function box_close(){$("#q_box").remove();$("#title_box").remove();$("#close_box").remove();$("#box_bg").remove();$("#q_content").css("display","none");$("#overlay").css("display","none")};