var PKG=PKG||{};soundManager.url="/scripts/soundmanager2/swf";(function(b){PKG.prmpt=PKG.prmpt||function(e){PKG.overlay("/go/apps/auth/prompt/"+(e||""))};PKG.login=PKG.login||function(e){PKG.overlay("/go/apps/auth/login/"+(e||""))};PKG.signup=PKG.signup||function(e){PKG.overlay("/go/apps/auth/signup/"+(e||""))};PKG.forgot=PKG.forgot||function(e){PKG.overlay("/go/apps/auth/forgot_password/"+(e||""))};PKG.overlay=PKG.overlay||function(e){b.fn.colorbox({href:e,onCleanup:function(){soundManager.pauseAll()},onComplete:function(){b("body").trigger("init.go")},overlayClose:false})};b("body").bind("cbox_open",function(){b("object, embed").each(function(){var e=b(this).attr("wmode");if(typeof e=="undefined"){e=b("object").find("param[name='wmode']").attr("value")}if((e!="transparent"&&e!="Transparent"&&e!="opaque"&&e!="Opaque")){this.style.visibility="hidden"}})});b("body").bind("cbox_closed",function(){b("object, embed").each(function(){this.style.visibility="visible"})});if(typeof(b.fn.colorbox)!="undefined"){b(document).ready(function(){b('a[href*="/go/apps/auth/"]').colorbox({onCleanup:function(){soundManager.pauseAll()},onComplete:function(){b("body").trigger("init.go")},overlayClose:false})});b.fn.colorbox.loading=function(){b("#go-auth").children().hide();b("#cboxLoadingOverlay").show();b("#cboxLoadingGraphic").show()}}var c={init:function(e,f){this.options=b.extend({},this.options,e);this.elem=f;this.$elem=b(f);this._addEventListeners()},options:{autoprint:true,content:null,directories:"no",fullscreen:"no",height:null,location:"no",menubar:"no",name:"printWindow",resizable:"no",scrollbars:"no",url:null,width:null},_addEventListeners:function(){this.$elem.bind("click.print",b.proxy(function(){this.newWindow();return false},this))},newWindow:function(){var f=this.options;var h=window.open(this.options.url,this.options.name,"width="+this.options.width+",height="+this.options.height+",directories="+this.options.directories+",fullscreen="+this.options.fullscreen+",location="+this.options.location+",menubar="+this.options.menubar+",resizable="+this.options.resizable+",scrollbars="+this.options.scrollbars);var e=function(){b(h.document.body).html(f.content);if(f.autoprint==true){var i=setTimeout(function(){h.print()},100)}};var g=setTimeout(e,500)}};var a={init:function(e,f){this.options=b.extend({},this.options,e);this.elem=f;this.$elem=b(f);this._addEventListeners()},options:{bevel:{bottom:"7px",right:"7px"},speed:{down:100,up:"slow"},throughClick:true},_addEventListeners:function(){this.$elem.bind("mouseenter",b.proxy(this.press,this));this.$elem.bind("mouseleave",b.proxy(this.release,this));if(this.options.throughClick==true){this.$elem.bind("click",b.proxy(this.throughClick,this))}},press:function(){this.$elem.stop().animate({left:this.options.bevel.right,top:this.options.bevel.bottom},this.options.speed.down)},release:function(){this.$elem.stop().animate({left:0,top:0},this.options.speed.up)},disable:function(e){var e=e||true;this.$elem.addClass("disabled");if(e==true){this.$elem.unbind().click(function(){return false})}},enable:function(e){this.$elem.removeClass("disabled");this.$elem.unbind("click");this._addEventListeners()},select:function(){this.$elem.addClass("selected").css({left:this.options.bevel.right,top:this.options.bevel.bottom}).unbind("mouseenter").unbind("mouseleave")},throughClick:function(){this.$elem.css({left:this.options.bevel.right,opacity:0.5,top:this.options.bevel.bottom}).click(function(){return false}).unbind("mouseleave")}};var d={init:function(e,f){this.options=b.extend({},this.options,e);this.elem=f;this.$elem=b(f);this.options.labelText=this.options.labelText||this.$elem.prev("label");if(this.options.useLabel==true){this.$elem.data("labelText",this.options.labelText.text())}else{this.$elem.data("labelText","")}this._build();this._addEventListeners();this.$elem.trigger("blur")},options:{hideLabel:true,labelText:null,useLabel:true},clear:function(){this.$elem.val("");this.$elem.removeClass("inactive").addClass("active")},empty:function(){if(this.$elem.val()==""||(this.$elem.val()==this.$elem.data("labelText"))){return true}else{return false}},reset:function(){this.$elem.val(this.$elem.data("labelText"));this.$elem.removeClass("active").addClass("inactive")},_build:function(){if(this.options.hideLabel==true){this.options.labelText.hide()}},_addEventListeners:function(){this.$elem.focus(b.proxy(function(){if(this.empty()==true){this.clear()}},this));this.$elem.blur(b.proxy(function(){if(this.empty()==true){this.reset()}},this))}};if(typeof Object.create!=="function"){Object.create=function(f){function e(){}e.prototype=f;return new e()}}b.plugin=function(f,e){b.fn[f]=function(h){var g=Array.prototype.slice.call(arguments,1);return this.each(function(){var i=b.data(this,f);if(i){i[h].apply(i,g)}else{i=b.data(this,f,Object.create(e));i.init(h,this)}})}};b.plugin("print",c);b.plugin("gobutton",a);b.plugin("label",d)})(jQuery);
/*
* jQuery Form Plugin
* version: 2.43 (12-MAR-2010)
* @requires jQuery v1.3.2 or later
*
* Examples and documentation at: http://malsup.com/jquery/form/
* Dual licensed under the MIT and GPL licenses:
* http://www.opensource.org/licenses/mit-license.php
* http://www.gnu.org/licenses/gpl.html
*/
(function(b){b.fn.ajaxSubmit=function(s){if(!this.length){a("ajaxSubmit: skipping submit process - no element selected");return this}if(typeof s=="function"){s={success:s}}var e=b.trim(this.attr("action"));if(e){e=(e.match(/^([^#]+)/)||[])[1]}e=e||window.location.href||"";s=b.extend({url:e,type:this.attr("method")||"GET",iframeSrc:/^https/i.test(window.location.href||"")?"javascript:false":"about:blank"},s||{});var u={};this.trigger("form-pre-serialize",[this,s,u]);if(u.veto){a("ajaxSubmit: submit vetoed via form-pre-serialize trigger");return this}if(s.beforeSerialize&&s.beforeSerialize(this,s)===false){a("ajaxSubmit: submit aborted via beforeSerialize callback");return this}var m=this.formToArray(s.semantic);if(s.data){s.extraData=s.data;for(var f in s.data){if(s.data[f] instanceof Array){for(var g in s.data[f]){m.push({name:f,value:s.data[f][g]})}}else{m.push({name:f,value:s.data[f]})}}}if(s.beforeSubmit&&s.beforeSubmit(m,this,s)===false){a("ajaxSubmit: submit aborted via beforeSubmit callback");return this}this.trigger("form-submit-validate",[m,this,s,u]);if(u.veto){a("ajaxSubmit: submit vetoed via form-submit-validate trigger");return this}var d=b.param(m);if(s.type.toUpperCase()=="GET"){s.url+=(s.url.indexOf("?")>=0?"&":"?")+d;s.data=null}else{s.data=d}var t=this,l=[];if(s.resetForm){l.push(function(){t.resetForm()})}if(s.clearForm){l.push(function(){t.clearForm()})}if(!s.dataType&&s.target){var p=s.success||function(){};l.push(function(k){var j=s.replaceTarget?"replaceWith":"html";b(s.target)[j](k).each(p,arguments)})}else{if(s.success){l.push(s.success)}}s.success=function(q,k,v){for(var n=0,j=l.length;n');var F=D[0];D.css({position:"absolute",top:"-1000px",left:"-1000px"});var G={aborted:0,responseText:null,responseXML:null,status:0,statusText:"n/a",getAllResponseHeaders:function(){},getResponseHeader:function(){},setRequestHeader:function(){},abort:function(){this.aborted=1;D.attr("src",q.iframeSrc)}};var E=q.global;if(E&&!b.active++){b.event.trigger("ajaxStart")}if(E){b.event.trigger("ajaxSend",[G,q])}if(H.beforeSend&&H.beforeSend(G,H)===false){H.global&&b.active--;return}if(G.aborted){return}var k=false;var A=0;var j=w.clk;if(j){var y=j.name;if(y&&!j.disabled){q.extraData=q.extraData||{};q.extraData[y]=j.value;if(j.type=="image"){q.extraData[y+".x"]=w.clk_x;q.extraData[y+".y"]=w.clk_y}}}function x(){var K=t.attr("target"),I=t.attr("action");w.setAttribute("target",v);if(w.getAttribute("method")!="POST"){w.setAttribute("method","POST")}if(w.getAttribute("action")!=q.url){w.setAttribute("action",q.url)}if(!q.skipEncodingOverride){t.attr({encoding:"multipart/form-data",enctype:"multipart/form-data"})}if(q.timeout){setTimeout(function(){A=true;B()},q.timeout)}var J=[];try{if(q.extraData){for(var L in q.extraData){J.push(b('').appendTo(w)[0])}}D.appendTo("body");D.data("form-plugin-onload",B);w.submit()}finally{w.setAttribute("action",I);K?w.setAttribute("target",K):t.removeAttr("target");b(J).remove()}}if(q.forceSync){x()}else{setTimeout(x,10)}var z=100;function B(){if(k){return}var I=true;try{if(A){throw"timeout"}var J,M;M=F.contentWindow?F.contentWindow.document:F.contentDocument?F.contentDocument:F.document;var N=q.dataType=="xml"||M.XMLDocument||b.isXMLDoc(M);a("isXml="+N);if(!N&&(M.body==null||M.body.innerHTML=="")){if(--z){a("requeing onLoad callback, DOM not available");setTimeout(B,250);return}a("Could not access iframe DOM after 100 tries.");return}a("response detected");k=true;G.responseText=M.body?M.body.innerHTML:null;G.responseXML=M.XMLDocument?M.XMLDocument:M;G.getResponseHeader=function(P){var O={"content-type":q.dataType};return O[P]};if(q.dataType=="json"||q.dataType=="script"){var n=M.getElementsByTagName("textarea")[0];if(n){G.responseText=n.value}else{var L=M.getElementsByTagName("pre")[0];if(L){G.responseText=L.innerHTML}}}else{if(q.dataType=="xml"&&!G.responseXML&&G.responseText!=null){G.responseXML=C(G.responseText)}}J=b.httpData(G,q.dataType)}catch(K){a("error caught:",K);I=false;G.error=K;b.handleError(q,G,"error",K)}if(I){q.success(J,"success");if(E){b.event.trigger("ajaxSuccess",[G,q])}}if(E){b.event.trigger("ajaxComplete",[G,q])}if(E&&!--b.active){b.event.trigger("ajaxStop")}if(q.complete){q.complete(G,I?"success":"error")}setTimeout(function(){D.removeData("form-plugin-onload");D.remove();G.responseXML=null},100)}function C(n,I){if(window.ActiveXObject){I=new ActiveXObject("Microsoft.XMLDOM");I.async="false";I.loadXML(n)}else{I=(new DOMParser()).parseFromString(n,"text/xml")}return(I&&I.documentElement&&I.documentElement.tagName!="parsererror")?I:null}}};b.fn.ajaxForm=function(c){return this.ajaxFormUnbind().bind("submit.form-plugin",function(d){d.preventDefault();b(this).ajaxSubmit(c)}).bind("click.form-plugin",function(i){var h=i.target;var f=b(h);if(!(f.is(":submit,input:image"))){var d=f.closest(":submit");if(d.length==0){return}h=d[0]}var g=this;g.clk=h;if(h.type=="image"){if(i.offsetX!=undefined){g.clk_x=i.offsetX;g.clk_y=i.offsetY}else{if(typeof b.fn.offset=="function"){var j=f.offset();g.clk_x=i.pageX-j.left;g.clk_y=i.pageY-j.top}else{g.clk_x=i.pageX-h.offsetLeft;g.clk_y=i.pageY-h.offsetTop}}}setTimeout(function(){g.clk=g.clk_x=g.clk_y=null},100)})};b.fn.ajaxFormUnbind=function(){return this.unbind("submit.form-plugin click.form-plugin")};b.fn.formToArray=function(q){var p=[];if(this.length==0){return p}var d=this[0];var h=q?d.getElementsByTagName("*"):d.elements;if(!h){return p}for(var k=0,m=h.length;k