(function(){if(typeof window.jQuery!="undefined"){var _jQuery=window.jQuery}var jQuery=window.jQuery=function(selector,context){return this instanceof jQuery?this.init(selector,context):new jQuery(selector,context)};if(typeof $!="undefined"){var _$=$}window.$=jQuery;var quickExpr=/^[^<]*(<(.|\s)+>)[^>]*$|^#(\w+)$/;jQuery.fn=jQuery.prototype={init:function(selector,context){selector=selector||document;if(typeof selector=="string"){var m=quickExpr.exec(selector);if(m&&(m[1]||!context)){if(m[1]){selector=jQuery.clean([m[1]],context)}else{var tmp=document.getElementById(m[3]);if(tmp){if(tmp.id!=m[3]){return jQuery().find(selector)}else{this[0]=tmp;this.length=1;return this}}else{selector=[]}}}else{return new jQuery(context).find(selector)}}else{if(jQuery.isFunction(selector)){return new jQuery(document)[jQuery.fn.ready?"ready":"load"](selector)}}return this.setArray(selector.constructor==Array&&selector||(selector.jquery||selector.length&&selector!=window&&!selector.nodeType&&selector[0]!=undefined&&selector[0].nodeType)&&jQuery.makeArray(selector)||[selector])},jquery:"1.2.1",size:function(){return this.length},length:0,get:function(num){return num==undefined?jQuery.makeArray(this):this[num]},pushStack:function(a){var ret=jQuery(a);ret.prevObject=this;return ret},setArray:function(a){this.length=0;Array.prototype.push.apply(this,a);return this},each:function(fn,args){return jQuery.each(this,fn,args)},index:function(obj){var pos=-1;this.each(function(i){if(this==obj){pos=i}});return pos},attr:function(key,value,type){var obj=key;if(key.constructor==String){if(value==undefined){return this.length&&jQuery[type||"attr"](this[0],key)||undefined}else{obj={};obj[key]=value}}return this.each(function(index){for(var prop in obj){jQuery.attr(type?this.style:this,prop,jQuery.prop(this,obj[prop],type,index,prop))}})},css:function(key,value){return this.attr(key,value,"curCSS")},text:function(e){if(typeof e!="object"&&e!=null){return this.empty().append(document.createTextNode(e))}var t="";jQuery.each(e||this,function(){jQuery.each(this.childNodes,function(){if(this.nodeType!=8){t+=this.nodeType!=1?this.nodeValue:jQuery.fn.text([this])}})});return t},wrapAll:function(html){if(this[0]){jQuery(html,this[0].ownerDocument).clone().insertBefore(this[0]).map(function(){var elem=this;while(elem.firstChild){elem=elem.firstChild}return elem}).append(this)}return this},wrapInner:function(html){return this.each(function(){jQuery(this).contents().wrapAll(html)})},wrap:function(html){return this.each(function(){jQuery(this).wrapAll(html)})},append:function(){return this.domManip(arguments,true,1,function(a){this.appendChild(a)})},prepend:function(){return this.domManip(arguments,true,-1,function(a){this.insertBefore(a,this.firstChild)})},before:function(){return this.domManip(arguments,false,1,function(a){this.parentNode.insertBefore(a,this)})},after:function(){return this.domManip(arguments,false,-1,function(a){this.parentNode.insertBefore(a,this.nextSibling)})},end:function(){return this.prevObject||jQuery([])},find:function(t){var data=jQuery.map(this,function(a){return jQuery.find(t,a)});return this.pushStack(/[^+>] [^+>]/.test(t)||t.indexOf("..")>-1?jQuery.unique(data):data)},clone:function(events){var ret=this.map(function(){return this.outerHTML?jQuery(this.outerHTML)[0]:this.cloneNode(true)});var clone=ret.find("*").andSelf().each(function(){if(this[expando]!=undefined){this[expando]=null}});if(events===true){this.find("*").andSelf().each(function(i){var events=jQuery.data(this,"events");for(var type in events){for(var handler in events[type]){jQuery.event.add(clone[i],type,events[type][handler],events[type][handler].data)}}})}return ret},filter:function(t){return this.pushStack(jQuery.isFunction(t)&&jQuery.grep(this,function(el,index){return t.apply(el,[index])})||jQuery.multiFilter(t,this))},not:function(t){return this.pushStack(t.constructor==String&&jQuery.multiFilter(t,this,true)||jQuery.grep(this,function(a){return(t.constructor==Array||t.jquery)?jQuery.inArray(a,t)<0:a!=t}))},add:function(t){return this.pushStack(jQuery.merge(this.get(),t.constructor==String?jQuery(t).get():t.length!=undefined&&(!t.nodeName||jQuery.nodeName(t,"form"))?t:[t]))},is:function(expr){return expr?jQuery.multiFilter(expr,this).length>0:false},hasClass:function(expr){return this.is("."+expr)},val:function(val){if(val==undefined){if(this.length){var elem=this[0];if(jQuery.nodeName(elem,"select")){var index=elem.selectedIndex,a=[],options=elem.options,one=elem.type=="select-one";if(index<0){return null}for(var i=one?index:0,max=one?index+1:options.length;i<max;i++){var option=options[i];if(option.selected){var val=jQuery.browser.msie&&!option.attributes["value"].specified?option.text:option.value;if(one){return val}a.push(val)}}return a}else{return this[0].value.replace(/\r/g,"")}}}else{return this.each(function(){if(val.constructor==Array&&/radio|checkbox/.test(this.type)){this.checked=(jQuery.inArray(this.value,val)>=0||jQuery.inArray(this.name,val)>=0)}else{if(jQuery.nodeName(this,"select")){var tmp=val.constructor==Array?val:[val];jQuery("option",this).each(function(){this.selected=(jQuery.inArray(this.value,tmp)>=0||jQuery.inArray(this.text,tmp)>=0)});if(!tmp.length){this.selectedIndex=-1}}else{this.value=val}}})}},html:function(val){return val==undefined?(this.length?this[0].innerHTML:null):this.empty().append(val)},replaceWith:function(val){return this.after(val).remove()},eq:function(i){return this.slice(i,i+1)},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments))},map:function(fn){return this.pushStack(jQuery.map(this,function(elem,i){return fn.call(elem,i,elem)}))},andSelf:function(){return this.add(this.prevObject)},domManip:function(args,table,dir,fn){var clone=this.length>1,a;return this.each(function(){if(!a){a=jQuery.clean(args,this.ownerDocument);if(dir<0){a.reverse()}}var obj=this;if(table&&jQuery.nodeName(this,"table")&&jQuery.nodeName(a[0],"tr")){obj=this.getElementsByTagName("tbody")[0]||this.appendChild(document.createElement("tbody"))}jQuery.each(a,function(){var elem=clone?this.cloneNode(true):this;if(!evalScript(0,elem)){fn.call(obj,elem)}})})}};function evalScript(i,elem){var script=jQuery.nodeName(elem,"script");if(script){if(elem.src){jQuery.ajax({url:elem.src,async:false,dataType:"script"})}else{jQuery.globalEval(elem.text||elem.textContent||elem.innerHTML||"")}if(elem.parentNode){elem.parentNode.removeChild(elem)}}else{if(elem.nodeType==1){jQuery("script",elem).each(evalScript)}}return script}jQuery.extend=jQuery.fn.extend=function(){var target=arguments[0]||{},a=1,al=arguments.length,deep=false;if(target.constructor==Boolean){deep=target;target=arguments[1]||{}}if(al==1){target=this;a=0}var prop;for(;a<al;a++){if((prop=arguments[a])!=null){for(var i in prop){if(target==prop[i]){continue}if(deep&&typeof prop[i]=="object"&&target[i]){jQuery.extend(target[i],prop[i])}else{if(prop[i]!=undefined){target[i]=prop[i]}}}}}return target};var expando="jQuery"+(new Date()).getTime(),uuid=0,win={};jQuery.extend({noConflict:function(deep){window.$=_$;if(deep){window.jQuery=_jQuery}return jQuery},isFunction:function(fn){return !!fn&&typeof fn!="string"&&!fn.nodeName&&fn.constructor!=Array&&/function/i.test(fn+"")},isXMLDoc:function(elem){return elem.documentElement&&!elem.body||elem.tagName&&elem.ownerDocument&&!elem.ownerDocument.body},globalEval:function(data){data=jQuery.trim(data);if(data){if(window.execScript){window.execScript(data)}else{if(jQuery.browser.safari){window.setTimeout(data,0)}else{eval.call(window,data)}}}},nodeName:function(elem,name){return elem.nodeName&&elem.nodeName.toUpperCase()==name.toUpperCase()},cache:{},data:function(elem,name,data){elem=elem==window?win:elem;var id=elem[expando];if(!id){id=elem[expando]=++uuid}if(name&&!jQuery.cache[id]){jQuery.cache[id]={}}if(data!=undefined){jQuery.cache[id][name]=data}return name?jQuery.cache[id][name]:id},removeData:function(elem,name){elem=elem==window?win:elem;var id=elem[expando];if(name){if(jQuery.cache[id]){delete jQuery.cache[id][name];name="";for(name in jQuery.cache[id]){break}if(!name){jQuery.removeData(elem)}}}else{try{delete elem[expando]}catch(e){if(elem.removeAttribute){elem.removeAttribute(expando)}}delete jQuery.cache[id]}},each:function(obj,fn,args){if(args){if(obj.length==undefined){for(var i in obj){fn.apply(obj[i],args)}}else{for(var i=0,ol=obj.length;i<ol;i++){if(fn.apply(obj[i],args)===false){break}}}}else{if(obj.length==undefined){for(var i in obj){fn.call(obj[i],i,obj[i])}}else{for(var i=0,ol=obj.length,val=obj[0];i<ol&&fn.call(val,i,val)!==false;val=obj[++i]){}}}return obj},prop:function(elem,value,type,index,prop){if(jQuery.isFunction(value)){value=value.call(elem,[index])}var exclude=/z-?index|font-?weight|opacity|zoom|line-?height/i;return value&&value.constructor==Number&&type=="curCSS"&&!exclude.test(prop)?value+"px":value},className:{add:function(elem,c){jQuery.each((c||"").split(/\s+/),function(i,cur){if(!jQuery.className.has(elem.className,cur)){elem.className+=(elem.className?" ":"")+cur}})},remove:function(elem,c){elem.className=c!=undefined?jQuery.grep(elem.className.split(/\s+/),function(cur){return !jQuery.className.has(c,cur)}).join(" "):""},has:function(t,c){return jQuery.inArray(c,(t.className||t).toString().split(/\s+/))>-1}},swap:function(e,o,f){for(var i in o){e.style["old"+i]=e.style[i];e.style[i]=o[i]}f.apply(e,[]);for(var i in o){e.style[i]=e.style["old"+i]}},css:function(e,p){if(p=="height"||p=="width"){var old={},oHeight,oWidth,d=["Top","Bottom","Right","Left"];jQuery.each(d,function(){old["padding"+this]=0;old["border"+this+"Width"]=0});jQuery.swap(e,old,function(){if(jQuery(e).is(":visible")){oHeight=e.offsetHeight;oWidth=e.offsetWidth}else{e=jQuery(e.cloneNode(true)).find(":radio").removeAttr("checked").end().css({visibility:"hidden",position:"absolute",display:"block",right:"0",left:"0"}).appendTo(e.parentNode)[0];var parPos=jQuery.css(e.parentNode,"position")||"static";if(parPos=="static"){e.parentNode.style.position="relative"}oHeight=e.clientHeight;oWidth=e.clientWidth;if(parPos=="static"){e.parentNode.style.position="static"}e.parentNode.removeChild(e)}});return p=="height"?oHeight:oWidth}return jQuery.curCSS(e,p)},curCSS:function(elem,prop,force){var ret,stack=[],swap=[];function color(a){if(!jQuery.browser.safari){return false}var ret=document.defaultView.getComputedStyle(a,null);return !ret||ret.getPropertyValue("color")==""}if(prop=="opacity"&&jQuery.browser.msie){ret=jQuery.attr(elem.style,"opacity");return ret==""?"1":ret}if(prop.match(/float/i)){prop=styleFloat}if(!force&&elem.style[prop]){ret=elem.style[prop]}else{if(document.defaultView&&document.defaultView.getComputedStyle){if(prop.match(/float/i)){prop="float"}prop=prop.replace(/([A-Z])/g,"-$1").toLowerCase();var cur=document.defaultView.getComputedStyle(elem,null);if(cur&&!color(elem)){ret=cur.getPropertyValue(prop)}else{for(var a=elem;a&&color(a);a=a.parentNode){stack.unshift(a)}for(a=0;a<stack.length;a++){if(color(stack[a])){swap[a]=stack[a].style.display;stack[a].style.display="block"}}ret=prop=="display"&&swap[stack.length-1]!=null?"none":document.defaultView.getComputedStyle(elem,null).getPropertyValue(prop)||"";for(a=0;a<swap.length;a++){if(swap[a]!=null){stack[a].style.display=swap[a]}}}if(prop=="opacity"&&ret==""){ret="1"}}else{if(elem.currentStyle){var newProp=prop.replace(/\-(\w)/g,function(m,c){return c.toUpperCase()});ret=elem.currentStyle[prop]||elem.currentStyle[newProp];if(!/^\d+(px)?$/i.test(ret)&&/^\d/.test(ret)){var style=elem.style.left;var runtimeStyle=elem.runtimeStyle.left;elem.runtimeStyle.left=elem.currentStyle.left;elem.style.left=ret||0;ret=elem.style.pixelLeft+"px";elem.style.left=style;elem.runtimeStyle.left=runtimeStyle}}}}return ret},clean:function(a,doc){var r=[];doc=doc||document;jQuery.each(a,function(i,arg){if(!arg){return }if(arg.constructor==Number){arg=arg.toString()}if(typeof arg=="string"){arg=arg.replace(/(<(\w+)[^>]*?)\/>/g,function(m,all,tag){return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area)$/i)?m:all+"></"+tag+">"});var s=jQuery.trim(arg).toLowerCase(),div=doc.createElement("div"),tb=[];var wrap=!s.indexOf("<opt")&&[1,"<select>","</select>"]||!s.indexOf("<leg")&&[1,"<fieldset>","</fieldset>"]||s.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"<table>","</table>"]||!s.indexOf("<tr")&&[2,"<table><tbody>","</tbody></table>"]||(!s.indexOf("<td")||!s.indexOf("<th"))&&[3,"<table><tbody><tr>","</tr></tbody></table>"]||!s.indexOf("<col")&&[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"]||jQuery.browser.msie&&[1,"div<div>","</div>"]||[0,"",""];div.innerHTML=wrap[1]+arg+wrap[2];while(wrap[0]--){div=div.lastChild}if(jQuery.browser.msie){if(!s.indexOf("<table")&&s.indexOf("<tbody")<0){tb=div.firstChild&&div.firstChild.childNodes}else{if(wrap[1]=="<table>"&&s.indexOf("<tbody")<0){tb=div.childNodes}}for(var n=tb.length-1;n>=0;--n){if(jQuery.nodeName(tb[n],"tbody")&&!tb[n].childNodes.length){tb[n].parentNode.removeChild(tb[n])}}if(/^\s/.test(arg)){div.insertBefore(doc.createTextNode(arg.match(/^\s*/)[0]),div.firstChild)}}arg=jQuery.makeArray(div.childNodes)}if(0===arg.length&&(!jQuery.nodeName(arg,"form")&&!jQuery.nodeName(arg,"select"))){return }if(arg[0]==undefined||jQuery.nodeName(arg,"form")||arg.options){r.push(arg)}else{r=jQuery.merge(r,arg)}});return r},attr:function(elem,name,value){var fix=jQuery.isXMLDoc(elem)?{}:jQuery.props;if(name=="selected"&&jQuery.browser.safari){elem.parentNode.selectedIndex}if(fix[name]){if(value!=undefined){elem[fix[name]]=value}return elem[fix[name]]}else{if(jQuery.browser.msie&&name=="style"){return jQuery.attr(elem.style,"cssText",value)}else{if(value==undefined&&jQuery.browser.msie&&jQuery.nodeName(elem,"form")&&(name=="action"||name=="method")){return elem.getAttributeNode(name).nodeValue}else{if(elem.tagName){if(value!=undefined){if(name=="type"&&jQuery.nodeName(elem,"input")&&elem.parentNode){throw"type property can't be changed"}elem.setAttribute(name,value)}if(jQuery.browser.msie&&/href|src/.test(name)&&!jQuery.isXMLDoc(elem)){return elem.getAttribute(name,2)}return elem.getAttribute(name)}else{if(name=="opacity"&&jQuery.browser.msie){if(value!=undefined){elem.zoom=1;elem.filter=(elem.filter||"").replace(/alpha\([^)]*\)/,"")+(parseFloat(value).toString()=="NaN"?"":"alpha(opacity="+value*100+")")}return elem.filter?(parseFloat(elem.filter.match(/opacity=([^)]*)/)[1])/100).toString():""}name=name.replace(/-([a-z])/ig,function(z,b){return b.toUpperCase()});if(value!=undefined){elem[name]=value}return elem[name]}}}}},trim:function(t){return(t||"").replace(/^\s+|\s+$/g,"")},makeArray:function(a){var r=[];if(typeof a!="array"){for(var i=0,al=a.length;i<al;i++){r.push(a[i])}}else{r=a.slice(0)}return r},inArray:function(b,a){for(var i=0,al=a.length;i<al;i++){if(a[i]==b){return i}}return -1},merge:function(first,second){if(jQuery.browser.msie){for(var i=0;second[i];i++){if(second[i].nodeType!=8){first.push(second[i])}}}else{for(var i=0;second[i];i++){first.push(second[i])}}return first},unique:function(first){var r=[],done={};try{for(var i=0,fl=first.length;i<fl;i++){var id=jQuery.data(first[i]);if(!done[id]){done[id]=true;r.push(first[i])}}}catch(e){r=first}return r},grep:function(elems,fn,inv){if(typeof fn=="string"){fn=eval("false||function(a,i){return "+fn+"}")}var result=[];for(var i=0,el=elems.length;i<el;i++){if(!inv&&fn(elems[i],i)||inv&&!fn(elems[i],i)){result.push(elems[i])}}return result},map:function(elems,fn){if(typeof fn=="string"){fn=eval("false||function(a){return "+fn+"}")}var result=[];for(var i=0,el=elems.length;i<el;i++){var val=fn(elems[i],i);if(val!==null&&val!=undefined){if(val.constructor!=Array){val=[val]}result=result.concat(val)}}return result}});var userAgent=navigator.userAgent.toLowerCase();jQuery.browser={version:(userAgent.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[])[1],safari:/webkit/.test(userAgent),opera:/opera/.test(userAgent),msie:/msie/.test(userAgent)&&!/opera/.test(userAgent),mozilla:/mozilla/.test(userAgent)&&!/(compatible|webkit)/.test(userAgent)};var styleFloat=jQuery.browser.msie?"styleFloat":"cssFloat";jQuery.extend({boxModel:!jQuery.browser.msie||document.compatMode=="CSS1Compat",styleFloat:jQuery.browser.msie?"styleFloat":"cssFloat",props:{"for":"htmlFor","class":"className","float":styleFloat,cssFloat:styleFloat,styleFloat:styleFloat,innerHTML:"innerHTML",className:"className",value:"value",disabled:"disabled",checked:"checked",readonly:"readOnly",selected:"selected",maxlength:"maxLength"}});jQuery.each({parent:"a.parentNode",parents:"jQuery.dir(a,'parentNode')",next:"jQuery.nth(a,2,'nextSibling')",prev:"jQuery.nth(a,2,'previousSibling')",nextAll:"jQuery.dir(a,'nextSibling')",prevAll:"jQuery.dir(a,'previousSibling')",siblings:"jQuery.sibling(a.parentNode.firstChild,a)",children:"jQuery.sibling(a.firstChild)",contents:"jQuery.nodeName(a,'iframe')?a.contentDocument||a.contentWindow.document:jQuery.makeArray(a.childNodes)"},function(i,n){jQuery.fn[i]=function(a){var ret=jQuery.map(this,n);if(a&&typeof a=="string"){ret=jQuery.multiFilter(a,ret)}return this.pushStack(jQuery.unique(ret))}});jQuery.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(i,n){jQuery.fn[i]=function(){var a=arguments;return this.each(function(){for(var j=0,al=a.length;j<al;j++){jQuery(a[j])[n](this)}})}});jQuery.each({removeAttr:function(key){jQuery.attr(this,key,"");this.removeAttribute(key)},addClass:function(c){jQuery.className.add(this,c)},removeClass:function(c){jQuery.className.remove(this,c)},toggleClass:function(c){jQuery.className[jQuery.className.has(this,c)?"remove":"add"](this,c)},remove:function(a){if(!a||jQuery.filter(a,[this]).r.length){jQuery.removeData(this);this.parentNode.removeChild(this)}},empty:function(){jQuery("*",this).each(function(){jQuery.removeData(this)});while(this.firstChild){this.removeChild(this.firstChild)}}},function(i,n){jQuery.fn[i]=function(){return this.each(n,arguments)}});jQuery.each(["Height","Width"],function(i,name){var n=name.toLowerCase();jQuery.fn[n]=function(h){return this[0]==window?jQuery.browser.safari&&self["inner"+name]||jQuery.boxModel&&Math.max(document.documentElement["client"+name],document.body["client"+name])||document.body["client"+name]:this[0]==document?Math.max(document.body["scroll"+name],document.body["offset"+name]):h==undefined?(this.length?jQuery.css(this[0],n):null):this.css(n,h.constructor==String?h:h+"px")}});var chars=jQuery.browser.safari&&parseInt(jQuery.browser.version)<417?"(?:[\\w*_-]|\\\\.)":"(?:[\\w\u0128-\uFFFF*_-]|\\\\.)",quickChild=new RegExp("^>\\s*("+chars+"+)"),quickID=new RegExp("^("+chars+"+)(#)("+chars+"+)"),quickClass=new RegExp("^([#.]?)("+chars+"*)");jQuery.extend({expr:{"":"m[2]=='*'||jQuery.nodeName(a,m[2])","#":"a.getAttribute('id')==m[2]",":":{lt:"i<m[3]-0",gt:"i>m[3]-0",nth:"m[3]-0==i",eq:"m[3]-0==i",first:"i==0",last:"i==r.length-1",even:"i%2==0",odd:"i%2","first-child":"a.parentNode.getElementsByTagName('*')[0]==a","last-child":"jQuery.nth(a.parentNode.lastChild,1,'previousSibling')==a","only-child":"!jQuery.nth(a.parentNode.lastChild,2,'previousSibling')",parent:"a.firstChild",empty:"!a.firstChild",contains:"(a.textContent||a.innerText||jQuery(a).text()||'').indexOf(m[3])>=0",visible:'"hidden"!=a.type&&jQuery.css(a,"display")!="none"&&jQuery.css(a,"visibility")!="hidden"',hidden:'"hidden"==a.type||jQuery.css(a,"display")=="none"||jQuery.css(a,"visibility")=="hidden"',enabled:"!a.disabled",disabled:"a.disabled",checked:"a.checked",selected:"a.selected||jQuery.attr(a,'selected')",text:"'text'==a.type",radio:"'radio'==a.type",checkbox:"'checkbox'==a.type",file:"'file'==a.type",password:"'password'==a.type",submit:"'submit'==a.type",image:"'image'==a.type",reset:"'reset'==a.type",button:'"button"==a.type||jQuery.nodeName(a,"button")',input:"/input|select|textarea|button/i.test(a.nodeName)",has:"jQuery.find(m[3],a).length",header:"/h\\d/i.test(a.nodeName)",animated:"jQuery.grep(jQuery.timers,function(fn){return a==fn.elem;}).length"}},parse:[/^(\[) *@?([\w-]+) *([!*$^~=]*) *('?"?)(.*?)\4 *\]/,/^(:)([\w-]+)\("?'?(.*?(\(.*?\))?[^(]*?)"?'?\)/,new RegExp("^([:.#]*)("+chars+"+)")],multiFilter:function(expr,elems,not){var old,cur=[];while(expr&&expr!=old){old=expr;var f=jQuery.filter(expr,elems,not);expr=f.t.replace(/^\s*,\s*/,"");cur=not?elems=f.r:jQuery.merge(cur,f.r)}return cur},find:function(t,context){if(typeof t!="string"){return[t]}if(context&&!context.nodeType){context=null}context=context||document;var ret=[context],done=[],last;while(t&&last!=t){var r=[];last=t;t=jQuery.trim(t);var foundToken=false;var re=quickChild;var m=re.exec(t);if(m){var nodeName=m[1].toUpperCase();for(var i=0;ret[i];i++){for(var c=ret[i].firstChild;c;c=c.nextSibling){if(c.nodeType==1&&(nodeName=="*"||c.nodeName.toUpperCase()==nodeName.toUpperCase())){r.push(c)}}}ret=r;t=t.replace(re,"");if(t.indexOf(" ")==0){continue}foundToken=true}else{re=/^([>+~])\s*(\w*)/i;if((m=re.exec(t))!=null){r=[];var nodeName=m[2],merge={};m=m[1];for(var j=0,rl=ret.length;j<rl;j++){var n=m=="~"||m=="+"?ret[j].nextSibling:ret[j].firstChild;for(;n;n=n.nextSibling){if(n.nodeType==1){var id=jQuery.data(n);if(m=="~"&&merge[id]){break}if(!nodeName||n.nodeName.toUpperCase()==nodeName.toUpperCase()){if(m=="~"){merge[id]=true}r.push(n)}if(m=="+"){break}}}}ret=r;t=jQuery.trim(t.replace(re,""));foundToken=true}}if(t&&!foundToken){if(!t.indexOf(",")){if(context==ret[0]){ret.shift()}done=jQuery.merge(done,ret);r=ret=[context];t=" "+t.substr(1,t.length)}else{var re2=quickID;var m=re2.exec(t);if(m){m=[0,m[2],m[3],m[1]]}else{re2=quickClass;m=re2.exec(t)}m[2]=m[2].replace(/\\/g,"");var elem=ret[ret.length-1];if(m[1]=="#"&&elem&&elem.getElementById&&!jQuery.isXMLDoc(elem)){var oid=elem.getElementById(m[2]);if((jQuery.browser.msie||jQuery.browser.opera)&&oid&&typeof oid.id=="string"&&oid.id!=m[2]){oid=jQuery('[@id="'+m[2]+'"]',elem)[0]}ret=r=oid&&(!m[3]||jQuery.nodeName(oid,m[3]))?[oid]:[]}else{for(var i=0;ret[i];i++){var tag=m[1]=="#"&&m[3]?m[3]:m[1]!=""||m[0]==""?"*":m[2];if(tag=="*"&&ret[i].nodeName.toLowerCase()=="object"){tag="param"}r=jQuery.merge(r,ret[i].getElementsByTagName(tag))}if(m[1]=="."){r=jQuery.classFilter(r,m[2])}if(m[1]=="#"){var tmp=[];for(var i=0;r[i];i++){if(r[i].getAttribute("id")==m[2]){tmp=[r[i]];break}}r=tmp}ret=r}t=t.replace(re2,"")}}if(t){var val=jQuery.filter(t,r);ret=r=val.r;t=jQuery.trim(val.t)}}if(t){ret=[]}if(ret&&context==ret[0]){ret.shift()}done=jQuery.merge(done,ret);return done},classFilter:function(r,m,not){m=" "+m+" ";var tmp=[];for(var i=0;r[i];i++){var pass=(" "+r[i].className+" ").indexOf(m)>=0;if(!not&&pass||not&&!pass){tmp.push(r[i])}}return tmp},filter:function(t,r,not){var last;while(t&&t!=last){last=t;var p=jQuery.parse,m;for(var i=0;p[i];i++){m=p[i].exec(t);if(m){t=t.substring(m[0].length);m[2]=m[2].replace(/\\/g,"");break}}if(!m){break}if(m[1]==":"&&m[2]=="not"){r=jQuery.filter(m[3],r,true).r}else{if(m[1]=="."){r=jQuery.classFilter(r,m[2],not)}else{if(m[1]=="["){var tmp=[],type=m[3];for(var i=0,rl=r.length;i<rl;i++){var a=r[i],z=a[jQuery.props[m[2]]||m[2]];if(z==null||/href|src|selected/.test(m[2])){z=jQuery.attr(a,m[2])||""}if((type==""&&!!z||type=="="&&z==m[5]||type=="!="&&z!=m[5]||type=="^="&&z&&!z.indexOf(m[5])||type=="$="&&z.substr(z.length-m[5].length)==m[5]||(type=="*="||type=="~=")&&z.indexOf(m[5])>=0)^not){tmp.push(a)}}r=tmp}else{if(m[1]==":"&&m[2]=="nth-child"){var merge={},tmp=[],test=/(\d*)n\+?(\d*)/.exec(m[3]=="even"&&"2n"||m[3]=="odd"&&"2n+1"||!/\D/.test(m[3])&&"n+"+m[3]||m[3]),first=(test[1]||1)-0,last=test[2]-0;for(var i=0,rl=r.length;i<rl;i++){var node=r[i],parentNode=node.parentNode,id=jQuery.data(parentNode);if(!merge[id]){var c=1;for(var n=parentNode.firstChild;n;n=n.nextSibling){if(n.nodeType==1){n.nodeIndex=c++}}merge[id]=true}var add=false;if(first==1){if(last==0||node.nodeIndex==last){add=true}}else{if((node.nodeIndex+last)%first==0){add=true}}if(add^not){tmp.push(node)}}r=tmp}else{var f=jQuery.expr[m[1]];if(typeof f!="string"){f=jQuery.expr[m[1]][m[2]]}f=eval("false||function(a,i){return "+f+"}");r=jQuery.grep(r,f,not)}}}}}return{r:r,t:t}},dir:function(elem,dir){var matched=[];var cur=elem[dir];while(cur&&cur!=document){if(cur.nodeType==1){matched.push(cur)}cur=cur[dir]}return matched},nth:function(cur,result,dir,elem){result=result||1;var num=0;for(;cur;cur=cur[dir]){if(cur.nodeType==1&&++num==result){break}}return cur},sibling:function(n,elem){var r=[];for(;n;n=n.nextSibling){if(n.nodeType==1&&(!elem||n!=elem)){r.push(n)}}return r}});jQuery.event={add:function(element,type,handler,data){if(jQuery.browser.msie&&element.setInterval!=undefined){element=window}if(!handler.guid){handler.guid=this.guid++}if(data!=undefined){var fn=handler;handler=function(){return fn.apply(this,arguments)};handler.data=data;handler.guid=fn.guid}var parts=type.split(".");type=parts[0];handler.type=parts[1];var events=jQuery.data(element,"events")||jQuery.data(element,"events",{});var handle=jQuery.data(element,"handle",function(){var val;if(typeof jQuery=="undefined"||jQuery.event.triggered){return val}val=jQuery.event.handle.apply(element,arguments);return val});var handlers=events[type];if(!handlers){handlers=events[type]={};if(element.addEventListener){element.addEventListener(type,handle,false)}else{element.attachEvent("on"+type,handle)}}handlers[handler.guid]=handler;this.global[type]=true},guid:1,global:{},remove:function(element,type,handler){var events=jQuery.data(element,"events"),ret,index;if(typeof type=="string"){var parts=type.split(".");type=parts[0]}if(events){if(type&&type.type){handler=type.handler;type=type.type}if(!type){for(type in events){this.remove(element,type)}}else{if(events[type]){if(handler){delete events[type][handler.guid]}else{for(handler in events[type]){if(!parts[1]||events[type][handler].type==parts[1]){delete events[type][handler]}}}for(ret in events[type]){break}if(!ret){if(element.removeEventListener){element.removeEventListener(type,jQuery.data(element,"handle"),false)}else{element.detachEvent("on"+type,jQuery.data(element,"handle"))}ret=null;delete events[type]}}}for(ret in events){break}if(!ret){jQuery.removeData(element,"events");jQuery.removeData(element,"handle")}}},trigger:function(type,data,element,donative,extra){data=jQuery.makeArray(data||[]);if(!element){if(this.global[type]){jQuery("*").add([window,document]).trigger(type,data)}}else{var val,ret,fn=jQuery.isFunction(element[type]||null),evt=!data[0]||!data[0].preventDefault;if(evt){data.unshift(this.fix({type:type,target:element}))}data[0].type=type;if(jQuery.isFunction(jQuery.data(element,"handle"))){val=jQuery.data(element,"handle").apply(element,data)}if(!fn&&element["on"+type]&&element["on"+type].apply(element,data)===false){val=false}if(evt){data.shift()}if(extra&&extra.apply(element,data)===false){val=false}if(fn&&donative!==false&&val!==false&&!(jQuery.nodeName(element,"a")&&type=="click")){this.triggered=true;element[type]()}this.triggered=false}return val},handle:function(event){var val;event=jQuery.event.fix(event||window.event||{});var parts=event.type.split(".");event.type=parts[0];var c=jQuery.data(this,"events")&&jQuery.data(this,"events")[event.type],args=Array.prototype.slice.call(arguments,1);args.unshift(event);for(var j in c){args[0].handler=c[j];args[0].data=c[j].data;if(!parts[1]||c[j].type==parts[1]){var tmp=c[j].apply(this,args);if(val!==false){val=tmp}if(tmp===false){event.preventDefault();event.stopPropagation()}}}if(jQuery.browser.msie){event.target=event.preventDefault=event.stopPropagation=event.handler=event.data=null}return val},fix:function(event){var originalEvent=event;event=jQuery.extend({},originalEvent);event.preventDefault=function(){if(originalEvent.preventDefault){originalEvent.preventDefault()}originalEvent.returnValue=false};event.stopPropagation=function(){if(originalEvent.stopPropagation){originalEvent.stopPropagation()}originalEvent.cancelBubble=true};if(!event.target&&event.srcElement){event.target=event.srcElement}if(jQuery.browser.safari&&event.target.nodeType==3){event.target=originalEvent.target.parentNode}if(!event.relatedTarget&&event.fromElement){event.relatedTarget=event.fromElement==event.target?event.toElement:event.fromElement}if(event.pageX==null&&event.clientX!=null){var e=document.documentElement,b=document.body;event.pageX=event.clientX+(e&&e.scrollLeft||b.scrollLeft||0);event.pageY=event.clientY+(e&&e.scrollTop||b.scrollTop||0)}if(!event.which&&(event.charCode||event.keyCode)){event.which=event.charCode||event.keyCode}if(!event.metaKey&&event.ctrlKey){event.metaKey=event.ctrlKey}if(!event.which&&event.button){event.which=(event.button&1?1:(event.button&2?3:(event.button&4?2:0)))}return event}};jQuery.fn.extend({bind:function(type,data,fn){return type=="unload"?this.one(type,data,fn):this.each(function(){jQuery.event.add(this,type,fn||data,fn&&data)})},one:function(type,data,fn){return this.each(function(){jQuery.event.add(this,type,function(event){jQuery(this).unbind(event);return(fn||data).apply(this,arguments)},fn&&data)})},unbind:function(type,fn){return this.each(function(){jQuery.event.remove(this,type,fn)})},trigger:function(type,data,fn){return this.each(function(){jQuery.event.trigger(type,data,this,true,fn)})},triggerHandler:function(type,data,fn){if(this[0]){return jQuery.event.trigger(type,data,this[0],false,fn)}},toggle:function(){var a=arguments;return this.click(function(e){this.lastToggle=0==this.lastToggle?1:0;e.preventDefault();return a[this.lastToggle].apply(this,[e])||false})},hover:function(f,g){function handleHover(e){var p=e.relatedTarget;while(p&&p!=this){try{p=p.parentNode}catch(e){p=this}}if(p==this){return false}return(e.type=="mouseover"?f:g).apply(this,[e])}return this.mouseover(handleHover).mouseout(handleHover)},ready:function(f){bindReady();if(jQuery.isReady){f.apply(document,[jQuery])}else{jQuery.readyList.push(function(){return f.apply(this,[jQuery])})}return this}});jQuery.extend({isReady:false,readyList:[],ready:function(){if(!jQuery.isReady){jQuery.isReady=true;if(jQuery.readyList){jQuery.each(jQuery.readyList,function(){this.apply(document)});jQuery.readyList=null}if(jQuery.browser.mozilla||jQuery.browser.opera){document.removeEventListener("DOMContentLoaded",jQuery.ready,false)}if(!window.frames.length){jQuery(window).load(function(){jQuery("#__ie_init").remove()})}}}});jQuery.each(("blur,focus,load,resize,scroll,unload,click,dblclick,mousedown,mouseup,mousemove,mouseover,mouseout,change,select,submit,keydown,keypress,keyup,error").split(","),function(i,o){jQuery.fn[o]=function(f){return f?this.bind(o,f):this.trigger(o)}});var readyBound=false;function bindReady(){if(readyBound){return }readyBound=true;if(jQuery.browser.mozilla||jQuery.browser.opera){document.addEventListener("DOMContentLoaded",jQuery.ready,false)}else{if(jQuery.browser.msie){document.write("<script id=__ie_init defer=true src=//:><\/script>");var script=document.getElementById("__ie_init");if(script){script.onreadystatechange=function(){if(this.readyState!="complete"){return }jQuery.ready()}}script=null}else{if(jQuery.browser.safari){jQuery.safariTimer=setInterval(function(){if(document.readyState=="loaded"||document.readyState=="complete"){clearInterval(jQuery.safariTimer);jQuery.safariTimer=null;jQuery.ready()}},10)}}}jQuery.event.add(window,"load",jQuery.ready)}jQuery.fn.extend({load:function(url,params,callback){if(jQuery.isFunction(url)){return this.bind("load",url)}var off=url.indexOf(" ");if(off>=0){var selector=url.slice(off,url.length);url=url.slice(0,off)}callback=callback||function(){};var type="GET";if(params){if(jQuery.isFunction(params)){callback=params;params=null}else{params=jQuery.param(params);type="POST"}}var self=this;jQuery.ajax({url:url,type:type,data:params,complete:function(res,status){if(status=="success"||status=="notmodified"){self.html(selector?jQuery("<div/>").append(res.responseText.replace(/<script(.|\s)*?\/script>/g,"")).find(selector):res.responseText)}setTimeout(function(){self.each(callback,[res.responseText,status,res])},13)}});return this},serialize:function(){return jQuery.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return jQuery.nodeName(this,"form")?jQuery.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password/i.test(this.type))}).map(function(i,elem){var val=jQuery(this).val();return val==null?null:val.constructor==Array?jQuery.map(val,function(val,i){return{name:elem.name,value:val}}):{name:elem.name,value:val}}).get()}});jQuery.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(i,o){jQuery.fn[o]=function(f){return this.bind(o,f)}});var jsc=(new Date).getTime();jQuery.extend({get:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data=null}return jQuery.ajax({type:"GET",url:url,data:data,success:callback,dataType:type})},getScript:function(url,callback){return jQuery.get(url,null,callback,"script")},getJSON:function(url,data,callback){return jQuery.get(url,data,callback,"json")},post:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data={}}return jQuery.ajax({type:"POST",url:url,data:data,success:callback,dataType:type})},ajaxSetup:function(settings){jQuery.extend(jQuery.ajaxSettings,settings)},ajaxSettings:{global:true,type:"GET",timeout:0,contentType:"application/x-www-form-urlencoded",processData:true,async:true,data:null},lastModified:{},ajax:function(s){var jsonp,jsre=/=(\?|%3F)/g,status,data;s=jQuery.extend(true,s,jQuery.extend(true,{},jQuery.ajaxSettings,s));if(s.data&&s.processData&&typeof s.data!="string"){s.data=jQuery.param(s.data)}if(s.dataType=="jsonp"){if(s.type.toLowerCase()=="get"){if(!s.url.match(jsre)){s.url+=(s.url.match(/\?/)?"&":"?")+(s.jsonp||"callback")+"=?"}}else{if(!s.data||!s.data.match(jsre)){s.data=(s.data?s.data+"&":"")+(s.jsonp||"callback")+"=?"}}s.dataType="json"}if(s.dataType=="json"&&(s.data&&s.data.match(jsre)||s.url.match(jsre))){jsonp="jsonp"+jsc++;if(s.data){s.data=s.data.replace(jsre,"="+jsonp)}s.url=s.url.replace(jsre,"="+jsonp);s.dataType="script";window[jsonp]=function(tmp){data=tmp;success();complete();window[jsonp]=undefined;try{delete window[jsonp]}catch(e){}}}if(s.dataType=="script"&&s.cache==null){s.cache=false}if(s.cache===false&&s.type.toLowerCase()=="get"){s.url+=(s.url.match(/\?/)?"&":"?")+"_="+(new Date()).getTime()}if(s.data&&s.type.toLowerCase()=="get"){s.url+=(s.url.match(/\?/)?"&":"?")+s.data;s.data=null}if(s.global&&!jQuery.active++){jQuery.event.trigger("ajaxStart")}if(!s.url.indexOf("http")&&s.dataType=="script"){var head=document.getElementsByTagName("head")[0];var script=document.createElement("script");script.src=s.url;if(!jsonp&&(s.success||s.complete)){var done=false;script.onload=script.onreadystatechange=function(){if(!done&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){done=true;success();complete();head.removeChild(script)}}}head.appendChild(script);return }var requestDone=false;var xml=window.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest();xml.open(s.type,s.url,s.async);if(s.data){xml.setRequestHeader("Content-Type",s.contentType)}if(s.ifModified){xml.setRequestHeader("If-Modified-Since",jQuery.lastModified[s.url]||"Thu, 01 Jan 1970 00:00:00 GMT")}xml.setRequestHeader("X-Requested-With","XMLHttpRequest");if(s.beforeSend){s.beforeSend(xml)}if(s.global){jQuery.event.trigger("ajaxSend",[xml,s])}var onreadystatechange=function(isTimeout){if(!requestDone&&xml&&(xml.readyState==4||isTimeout=="timeout")){requestDone=true;if(ival){clearInterval(ival);ival=null}status=isTimeout=="timeout"&&"timeout"||!jQuery.httpSuccess(xml)&&"error"||s.ifModified&&jQuery.httpNotModified(xml,s.url)&&"notmodified"||"success";if(status=="success"){try{data=jQuery.httpData(xml,s.dataType)}catch(e){status="parsererror"}}if(status=="success"){var modRes;try{modRes=xml.getResponseHeader("Last-Modified")}catch(e){}if(s.ifModified&&modRes){jQuery.lastModified[s.url]=modRes}if(!jsonp){success()}}else{jQuery.handleError(s,xml,status)}complete();if(s.async){xml=null}}};if(s.async){var ival=setInterval(onreadystatechange,13);if(s.timeout>0){setTimeout(function(){if(xml){xml.abort();if(!requestDone){onreadystatechange("timeout")}}},s.timeout)}}try{xml.send(s.data)}catch(e){jQuery.handleError(s,xml,null,e)}if(!s.async){onreadystatechange()}return xml;function success(){if(s.success){s.success(data,status)}if(s.global){jQuery.event.trigger("ajaxSuccess",[xml,s])}}function complete(){if(s.complete){s.complete(xml,status)}if(s.global){jQuery.event.trigger("ajaxComplete",[xml,s])}if(s.global&&!--jQuery.active){jQuery.event.trigger("ajaxStop")}}},handleError:function(s,xml,status,e){if(s.error){s.error(xml,status,e)}if(s.global){jQuery.event.trigger("ajaxError",[xml,s,e])}},active:0,httpSuccess:function(r){try{return !r.status&&location.protocol=="file:"||(r.status>=200&&r.status<300)||r.status==304||jQuery.browser.safari&&r.status==undefined}catch(e){}return false},httpNotModified:function(xml,url){try{var xmlRes=xml.getResponseHeader("Last-Modified");return xml.status==304||xmlRes==jQuery.lastModified[url]||jQuery.browser.safari&&xml.status==undefined}catch(e){}return false},httpData:function(r,type){var ct=r.getResponseHeader("content-type");var xml=type=="xml"||!type&&ct&&ct.indexOf("xml")>=0;var data=xml?r.responseXML:r.responseText;if(xml&&data.documentElement.tagName=="parsererror"){throw"parsererror"}if(type=="script"){jQuery.globalEval(data)}if(type=="json"){data=eval("("+data+")")}return data},param:function(a){var s=[];if(a.constructor==Array||a.jquery){jQuery.each(a,function(){s.push(encodeURIComponent(this.name)+"="+encodeURIComponent(this.value))})}else{for(var j in a){if(a[j]&&a[j].constructor==Array){jQuery.each(a[j],function(){s.push(encodeURIComponent(j)+"="+encodeURIComponent(this))})}else{s.push(encodeURIComponent(j)+"="+encodeURIComponent(a[j]))}}}return s.join("&").replace(/%20/g,"+")}});jQuery.fn.extend({show:function(speed,callback){return speed?this.animate({height:"show",width:"show",opacity:"show"},speed,callback):this.filter(":hidden").each(function(){this.style.display=this.oldblock?this.oldblock:"";if(jQuery.css(this,"display")=="none"){this.style.display="block"}}).end()},hide:function(speed,callback){return speed?this.animate({height:"hide",width:"hide",opacity:"hide"},speed,callback):this.filter(":visible").each(function(){this.oldblock=this.oldblock||jQuery.css(this,"display");if(this.oldblock=="none"){this.oldblock="block"}this.style.display="none"}).end()},_toggle:jQuery.fn.toggle,toggle:function(fn,fn2){return jQuery.isFunction(fn)&&jQuery.isFunction(fn2)?this._toggle(fn,fn2):fn?this.animate({height:"toggle",width:"toggle",opacity:"toggle"},fn,fn2):this.each(function(){jQuery(this)[jQuery(this).is(":hidden")?"show":"hide"]()})},slideDown:function(speed,callback){return this.animate({height:"show"},speed,callback)},slideUp:function(speed,callback){return this.animate({height:"hide"},speed,callback)},slideToggle:function(speed,callback){return this.animate({height:"toggle"},speed,callback)},fadeIn:function(speed,callback){return this.animate({opacity:"show"},speed,callback)},fadeOut:function(speed,callback){return this.animate({opacity:"hide"},speed,callback)},fadeTo:function(speed,to,callback){return this.animate({opacity:to},speed,callback)},animate:function(prop,speed,easing,callback){var opt=jQuery.speed(speed,easing,callback);return this[opt.queue===false?"each":"queue"](function(){opt=jQuery.extend({},opt);var hidden=jQuery(this).is(":hidden"),self=this;for(var p in prop){if(prop[p]=="hide"&&hidden||prop[p]=="show"&&!hidden){return jQuery.isFunction(opt.complete)&&opt.complete.apply(this)}if(p=="height"||p=="width"){opt.display=jQuery.css(this,"display");opt.overflow=this.style.overflow}}if(opt.overflow!=null){this.style.overflow="hidden"}opt.curAnim=jQuery.extend({},prop);jQuery.each(prop,function(name,val){var e=new jQuery.fx(self,opt,name);if(/toggle|show|hide/.test(val)){e[val=="toggle"?hidden?"show":"hide":val](prop)}else{var parts=val.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),start=e.cur(true)||0;if(parts){var end=parseFloat(parts[2]),unit=parts[3]||"px";if(unit!="px"){self.style[name]=(end||1)+unit;start=((end||1)/e.cur(true))*start;self.style[name]=start+unit}if(parts[1]){end=((parts[1]=="-="?-1:1)*end)+start}e.custom(start,end,unit)}else{e.custom(start,val,"")}}});return true})},queue:function(type,fn){if(jQuery.isFunction(type)){fn=type;type="fx"}if(!type||(typeof type=="string"&&!fn)){return queue(this[0],type)}return this.each(function(){if(fn.constructor==Array){queue(this,type,fn)}else{queue(this,type).push(fn);if(queue(this,type).length==1){fn.apply(this)}}})},stop:function(){var timers=jQuery.timers;return this.each(function(){for(var i=0;i<timers.length;i++){if(timers[i].elem==this){timers.splice(i--,1)}}}).dequeue()}});var queue=function(elem,type,array){if(!elem){return }var q=jQuery.data(elem,type+"queue");if(!q||array){q=jQuery.data(elem,type+"queue",array?jQuery.makeArray(array):[])}return q};jQuery.fn.dequeue=function(type){type=type||"fx";return this.each(function(){var q=queue(this,type);q.shift();if(q.length){q[0].apply(this)}})};jQuery.extend({speed:function(speed,easing,fn){var opt=speed&&speed.constructor==Object?speed:{complete:fn||!fn&&easing||jQuery.isFunction(speed)&&speed,duration:speed,easing:fn&&easing||easing&&easing.constructor!=Function&&easing};opt.duration=(opt.duration&&opt.duration.constructor==Number?opt.duration:{slow:600,fast:200}[opt.duration])||400;opt.old=opt.complete;opt.complete=function(){jQuery(this).dequeue();if(jQuery.isFunction(opt.old)){opt.old.apply(this)}};return opt},easing:{linear:function(p,n,firstNum,diff){return firstNum+diff*p},swing:function(p,n,firstNum,diff){return((-Math.cos(p*Math.PI)/2)+0.5)*diff+firstNum}},timers:[],fx:function(elem,options,prop){this.options=options;this.elem=elem;this.prop=prop;if(!options.orig){options.orig={}}}});jQuery.fx.prototype={update:function(){if(this.options.step){this.options.step.apply(this.elem,[this.now,this])}(jQuery.fx.step[this.prop]||jQuery.fx.step._default)(this);if(this.prop=="height"||this.prop=="width"){this.elem.style.display="block"}},cur:function(force){if(this.elem[this.prop]!=null&&this.elem.style[this.prop]==null){return this.elem[this.prop]}var r=parseFloat(jQuery.curCSS(this.elem,this.prop,force));return r&&r>-10000?r:parseFloat(jQuery.css(this.elem,this.prop))||0},custom:function(from,to,unit){this.startTime=(new Date()).getTime();this.start=from;this.end=to;this.unit=unit||this.unit||"px";this.now=this.start;this.pos=this.state=0;this.update();var self=this;function t(){return self.step()}t.elem=this.elem;jQuery.timers.push(t);if(jQuery.timers.length==1){var timer=setInterval(function(){var timers=jQuery.timers;for(var i=0;i<timers.length;i++){if(!timers[i]()){timers.splice(i--,1)}}if(!timers.length){clearInterval(timer)}},13)}},show:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.show=true;this.custom(0,this.cur());if(this.prop=="width"||this.prop=="height"){this.elem.style[this.prop]="1px"}jQuery(this.elem).show()},hide:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.hide=true;this.custom(this.cur(),0)},step:function(){var t=(new Date()).getTime();if(t>this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var done=true;for(var i in this.options.curAnim){if(this.options.curAnim[i]!==true){done=false}}if(done){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(jQuery.css(this.elem,"display")=="none"){this.elem.style.display="block"}}if(this.options.hide){this.elem.style.display="none"}if(this.options.hide||this.options.show){for(var p in this.options.curAnim){jQuery.attr(this.elem.style,p,this.options.orig[p])}}}if(done&&jQuery.isFunction(this.options.complete)){this.options.complete.apply(this.elem)}return false}else{var n=t-this.startTime;this.state=n/this.options.duration;this.pos=jQuery.easing[this.options.easing||(jQuery.easing.swing?"swing":"linear")](this.state,n,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update()}return true}};jQuery.fx.step={scrollLeft:function(fx){fx.elem.scrollLeft=fx.now},scrollTop:function(fx){fx.elem.scrollTop=fx.now},opacity:function(fx){jQuery.attr(fx.elem.style,"opacity",fx.now)},_default:function(fx){fx.elem.style[fx.prop]=fx.now+fx.unit}};jQuery.fn.offset=function(){var left=0,top=0,elem=this[0],results;if(elem){with(jQuery.browser){var absolute=jQuery.css(elem,"position")=="absolute",parent=elem.parentNode,offsetParent=elem.offsetParent,doc=elem.ownerDocument,safari2=safari&&parseInt(version)<522;if(elem.getBoundingClientRect){box=elem.getBoundingClientRect();add(box.left+Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),box.top+Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));if(msie){var border=jQuery("html").css("borderWidth");border=(border=="medium"||jQuery.boxModel&&parseInt(version)>=7)&&2||border;add(-border,-border)}}else{add(elem.offsetLeft,elem.offsetTop);while(offsetParent){add(offsetParent.offsetLeft,offsetParent.offsetTop);if(mozilla&&/^t[d|h]$/i.test(parent.tagName)||!safari2){border(offsetParent)}if(safari2&&!absolute&&jQuery.css(offsetParent,"position")=="absolute"){absolute=true}offsetParent=offsetParent.offsetParent}while(parent.tagName&&!/^body|html$/i.test(parent.tagName)){if(!/^inline|table-row.*$/i.test(jQuery.css(parent,"display"))){add(-parent.scrollLeft,-parent.scrollTop)}if(mozilla&&jQuery.css(parent,"overflow")!="visible"){border(parent)}parent=parent.parentNode}if(safari2&&absolute){add(-doc.body.offsetLeft,-doc.body.offsetTop)}}results={top:top,left:left}}}return results;function border(elem){add(jQuery.css(elem,"borderLeftWidth"),jQuery.css(elem,"borderTopWidth"))}function add(l,t){left+=parseInt(l)||0;top+=parseInt(t)||0}}})();(function(B){B.dimensions={version:"@VERSION"};B.each(["Height","Width"],function(D,C){B.fn["inner"+C]=function(){if(!this[0]){return }var F=C=="Height"?"Top":"Left",E=C=="Height"?"Bottom":"Right";return this[C.toLowerCase()]()+A(this,"padding"+F)+A(this,"padding"+E)};B.fn["outer"+C]=function(F){if(!this[0]){return }var G=C=="Height"?"Top":"Left",E=C=="Height"?"Bottom":"Right";F=B.extend({margin:false},F||{});return this[C.toLowerCase()]()+A(this,"border"+G+"Width")+A(this,"border"+E+"Width")+A(this,"padding"+G)+A(this,"padding"+E)+(F.margin?(A(this,"margin"+G)+A(this,"margin"+E)):0)}});B.each(["Left","Top"],function(D,C){B.fn["scroll"+C]=function(E){if(!this[0]){return }return E!=undefined?this.each(function(){this==window||this==document?window.scrollTo(C=="Left"?E:B(window)["scrollLeft"](),C=="Top"?E:B(window)["scrollTop"]()):this["scroll"+C]=E}):this[0]==window||this[0]==document?self[(C=="Left"?"pageXOffset":"pageYOffset")]||B.boxModel&&document.documentElement["scroll"+C]||document.body["scroll"+C]:this[0]["scroll"+C]}});B.fn.extend({position:function(){var H=0,G=0,F=this[0],I,C,E,D;if(F){E=this.offsetParent();I=this.offset();C=E.offset();I.top-=A(F,"marginTop");I.left-=A(F,"marginLeft");C.top+=A(E,"borderTopWidth");C.left+=A(E,"borderLeftWidth");D={top:I.top-C.top,left:I.left-C.left}}return D},offsetParent:function(){var C=this[0].offsetParent;while(C&&(!/^body|html$/i.test(C.tagName)&&B.css(C,"position")=="static")){C=C.offsetParent}return B(C)}});var A=function(C,D){return parseInt(B.css(C.jquery?C[0]:C,D))||0}})(jQuery);(function(C){C.ui=C.ui||{};C.extend(C.ui,{plugin:{add:function(F,I,H,G){var E=C.ui[F].prototype;if(!E.plugins[I]){E.plugins[I]=[]}E.plugins[I].push([H,G])},call:function(E,F,H){var K=E.plugins[F];if(!K){return }var J=E.interaction?E.interaction.options:E.options;var I=E.interaction?E.interaction.element:E.element;for(var G=0;G<K.length;G++){if(J[K[G][0]]){K[G][1].apply(I,H)}}}}});C.fn.mouseInteractionDestroy=function(){this.each(function(){if(C.data(this,"ui-mouse")){C.data(this,"ui-mouse").destroy()}})};C.ui.mouseInteraction=function(F,G){if(!G){var G={}}this.element=F;C.data(this.element,"ui-mouse",this);this.options={};C.extend(this.options,G);C.extend(this.options,{handle:G.handle?(C(G.handle,F)[0]?C(G.handle,F):C(F)):C(F),helper:G.helper||"original",preventionDistance:G.preventionDistance||0,dragPrevention:G.dragPrevention?G.dragPrevention.toLowerCase().split(","):["input","textarea","button","select","option"],cursorAt:{top:((G.cursorAt&&G.cursorAt.top)?G.cursorAt.top:0),left:((G.cursorAt&&G.cursorAt.left)?G.cursorAt.left:0),bottom:((G.cursorAt&&G.cursorAt.bottom)?G.cursorAt.bottom:0),right:((G.cursorAt&&G.cursorAt.right)?G.cursorAt.right:0)},cursorAtIgnore:(!G.cursorAt)?true:false,appendTo:G.appendTo||"parent"});G=this.options;if(!this.options.nonDestructive&&(G.helper=="clone"||G.helper=="original")){G.margins={top:parseInt(C(F).css("marginTop"))||0,left:parseInt(C(F).css("marginLeft"))||0,bottom:parseInt(C(F).css("marginBottom"))||0,right:parseInt(C(F).css("marginRight"))||0};if(G.cursorAt.top!=0){G.cursorAt.top=G.margins.top}if(G.cursorAt.left!=0){G.cursorAt.left+=G.margins.left}if(G.cursorAt.bottom!=0){G.cursorAt.bottom+=G.margins.bottom}if(G.cursorAt.right!=0){G.cursorAt.right+=G.margins.right}if(G.helper=="original"){G.wasPositioned=C(F).css("position")}}else{G.margins={top:0,left:0,right:0,bottom:0}}var E=this;this.mousedownfunc=function(H){return E.click.apply(E,[H])};G.handle.bind("mousedown",this.mousedownfunc);if(C.browser.msie){C(this.element).attr("unselectable","on")}};C.extend(C.ui.mouseInteraction.prototype,{plugins:{},currentTarget:null,lastTarget:null,timer:null,slowMode:false,init:false,destroy:function(){this.options.handle.unbind("mousedown",this.mousedownfunc)},trigger:function(E){return this.click.apply(this,arguments)},click:function(H){var I=this.options;window.focus();if(H.which!=1){return true}var G=(H.target)?H.target.nodeName.toLowerCase():H.srcElement.nodeName.toLowerCase();for(var F=0;F<I.dragPrevention.length;F++){if(G==I.dragPrevention[F]){return true}}if(I.startCondition&&!I.startCondition.apply(this,[H])){return true}var E=this;this.mouseup=function(K){return E.stop.apply(E,[K])};this.mousemove=function(K){return E.drag.apply(E,[K])};var J=function(){C(document).bind("mouseup",E.mouseup);C(document).bind("mousemove",E.mousemove);E.opos=[H.pageX,H.pageY]};if(I.preventionTimeout){if(this.timer){clearInterval(this.timer)}this.timer=setTimeout(function(){J()},I.preventionTimeout);return false}J();return false},start:function(G){var H=this.options;var E=this.element;H.co=C(E).offset();this.helper=typeof H.helper=="function"?C(H.helper.apply(E,[G,this]))[0]:(H.helper=="clone"?C(E).clone()[0]:E);if(H.appendTo=="parent"){var F=E.parentNode;while(F){if(F.style&&(C(F).css("position")=="relative"||C(F).css("position")=="absolute")){H.pp=F;H.po=C(F).offset();H.ppOverflow=!!(C(H.pp).css("overflow")=="auto"||C(H.pp).css("overflow")=="scroll");break}F=F.parentNode?F.parentNode:null}if(!H.pp){H.po={top:0,left:0}}}this.pos=[this.opos[0],this.opos[1]];this.rpos=[this.pos[0],this.pos[1]];if(H.cursorAtIgnore){H.cursorAt.left=this.pos[0]-H.co.left+H.margins.left;H.cursorAt.top=this.pos[1]-H.co.top+H.margins.top}if(H.pp){this.pos[0]-=H.po.left;this.pos[1]-=H.po.top}this.slowMode=(H.cursorAt&&(H.cursorAt.top-H.margins.top>0||H.cursorAt.bottom-H.margins.bottom>0)&&(H.cursorAt.left-H.margins.left>0||H.cursorAt.right-H.margins.right>0))?true:false;if(!H.nonDestructive){C(this.helper).css("position","absolute")}if(H.helper!="original"){C(this.helper).appendTo((H.appendTo=="parent"?E.parentNode:H.appendTo)).show()}if(H.cursorAt.right&&!H.cursorAt.left){H.cursorAt.left=this.helper.offsetWidth+H.margins.right+H.margins.left-H.cursorAt.right}if(H.cursorAt.bottom&&!H.cursorAt.top){H.cursorAt.top=this.helper.offsetHeight+H.margins.top+H.margins.bottom-H.cursorAt.bottom}this.init=true;if(H._start){H._start.apply(E,[this.helper,this.pos,H.cursorAt,this,G])}this.helperSize={width:D(this.helper),height:B(this.helper)};return false},stop:function(G){var H=this.options;var E=this.element;var F=this;C(document).unbind("mouseup",F.mouseup);C(document).unbind("mousemove",F.mousemove);if(this.init==false){return this.opos=this.pos=null}if(H._beforeStop){H._beforeStop.apply(E,[this.helper,this.pos,H.cursorAt,this,G])}if(this.helper!=E&&!H.beQuietAtEnd){C(this.helper).remove();this.helper=null}if(!H.beQuietAtEnd){if(H._stop){H._stop.apply(E,[this.helper,this.pos,H.cursorAt,this,G])}}this.init=false;this.opos=this.pos=null;return false},drag:function(E){if(!this.opos||(C.browser.msie&&!E.button)){return this.stop.apply(this,[E])}var F=this.options;this.pos=[E.pageX,E.pageY];if(this.rpos&&this.rpos[0]==this.pos[0]&&this.rpos[1]==this.pos[1]){return false}this.rpos=[this.pos[0],this.pos[1]];if(F.pp){this.pos[0]-=F.po.left;this.pos[1]-=F.po.top}if((Math.abs(this.rpos[0]-this.opos[0])>F.preventionDistance||Math.abs(this.rpos[1]-this.opos[1])>F.preventionDistance)&&this.init==false){this.start.apply(this,[E])}else{if(this.init==false){return false}}if(F._drag){F._drag.apply(this.element,[this.helper,this.pos,F.cursorAt,this,E])}return false}});var A=function(E,F){return parseInt(C.css(E.jquery?E[0]:E,F))||0};function D(I){var G=C(I),E=G.width();for(var F=0,H=["borderLeftWidth","paddingLeft","paddingRight","borderRightWidth"];F<H.length;F++){E+=A(G,H[F])}return E}function B(H){var F=C(H),I=F.width();for(var E=0,G=["borderTopWidth","paddingTop","paddingBottom","borderBottomWidth"];E<G.length;E++){I+=A(F,G[E])}return I}})($);(function($){$.extend($.expr[":"],{draggable:"(' '+a.className+' ').indexOf(' ui-draggable ')"});var methods="destroy,enable,disable".split(",");for(var i=0;i<methods.length;i++){var cur=methods[i],f;eval('f = function() { var a = arguments; return this.each(function() { if(jQuery(this).is(".ui-draggable")) jQuery.data(this, "ui-draggable")["'+cur+'"](a); }); }');$.fn["draggable"+cur.substr(0,1).toUpperCase()+cur.substr(1)]=f}$.fn.draggableInstance=function(){if($(this[0]).is(".ui-draggable")){return $.data(this[0],"ui-draggable")}return false};$.fn.draggable=function(o){return this.each(function(){new $.ui.draggable(this,o)})};$.ui.ddmanager={current:null,droppables:[],prepareOffsets:function(t,e){var dropTop=$.ui.ddmanager.dropTop=[];var dropLeft=$.ui.ddmanager.dropLeft;var m=$.ui.ddmanager.droppables;for(var i=0;i<m.length;i++){if(m[i].item.disabled){continue}m[i].offset=$(m[i].item.element).offset();if(t&&m[i].item.options.accept(t.element)){m[i].item.activate.call(m[i].item,e)}}},fire:function(oDrag,e){var oDrops=$.ui.ddmanager.droppables;var oOvers=$.grep(oDrops,function(oDrop){if(!oDrop.item.disabled&&$.ui.intersect(oDrag,oDrop,oDrop.item.options.tolerance)){oDrop.item.drop.call(oDrop.item,e)}});$.each(oDrops,function(i,oDrop){if(!oDrop.item.disabled&&oDrop.item.options.accept(oDrag.element)){oDrop.out=1;oDrop.over=0;oDrop.item.deactivate.call(oDrop.item,e)}})},update:function(oDrag,e){if(oDrag.options.refreshPositions){$.ui.ddmanager.prepareOffsets()}var oDrops=$.ui.ddmanager.droppables;var oOvers=$.grep(oDrops,function(oDrop){if(oDrop.item.disabled){return false}var isOver=$.ui.intersect(oDrag,oDrop,oDrop.item.options.tolerance);if(!isOver&&oDrop.over==1){oDrop.out=1;oDrop.over=0;oDrop.item.out.call(oDrop.item,e)}return isOver});$.each(oOvers,function(i,oOver){if(oOver.over==0){oOver.out=0;oOver.over=1;oOver.item.over.call(oOver.item,e)}})}};$.ui.draggable=function(el,o){var options={};$.extend(options,o);var self=this;$.extend(options,{_start:function(h,p,c,t,e){self.start.apply(t,[self,e])},_beforeStop:function(h,p,c,t,e){self.stop.apply(t,[self,e])},_drag:function(h,p,c,t,e){self.drag.apply(t,[self,e])},startCondition:function(e){return !(e.target.className.indexOf("ui-resizable-handle")!=-1||self.disabled)}});$.data(el,"ui-draggable",this);if(options.ghosting==true){options.helper="clone"}$(el).addClass("ui-draggable");this.interaction=new $.ui.mouseInteraction(el,options)};$.extend($.ui.draggable.prototype,{plugins:{},currentTarget:null,lastTarget:null,destroy:function(){$(this.interaction.element).removeClass("ui-draggable").removeClass("ui-draggable-disabled");this.interaction.destroy()},enable:function(){$(this.interaction.element).removeClass("ui-draggable-disabled");this.disabled=false},disable:function(){$(this.interaction.element).addClass("ui-draggable-disabled");this.disabled=true},prepareCallbackObj:function(self){return{helper:self.helper,position:{left:self.pos[0],top:self.pos[1]},offset:self.options.cursorAt,draggable:self,options:self.options}},start:function(that,e){var o=this.options;$.ui.ddmanager.current=this;$.ui.plugin.call(that,"start",[e,that.prepareCallbackObj(this)]);$(this.element).triggerHandler("dragstart",[e,that.prepareCallbackObj(this)],o.start);if(this.slowMode&&$.ui.droppable&&!o.dropBehaviour){$.ui.ddmanager.prepareOffsets(this,e)}return false},stop:function(that,e){var o=this.options;$.ui.plugin.call(that,"stop",[e,that.prepareCallbackObj(this)]);$(this.element).triggerHandler("dragstop",[e,that.prepareCallbackObj(this)],o.stop);if(this.slowMode&&$.ui.droppable&&!o.dropBehaviour){$.ui.ddmanager.fire(this,e)}$.ui.ddmanager.current=null;$.ui.ddmanager.last=this;return false},drag:function(that,e){var o=this.options;$.ui.ddmanager.update(this,e);this.pos=[this.pos[0]-o.cursorAt.left,this.pos[1]-o.cursorAt.top];$.ui.plugin.call(that,"drag",[e,that.prepareCallbackObj(this)]);var nv=$(this.element).triggerHandler("drag",[e,that.prepareCallbackObj(this)],o.drag);var nl=(nv&&nv.left)?nv.left:this.pos[0];var nt=(nv&&nv.top)?nv.top:this.pos[1];$(this.helper).css("left",nl+"px").css("top",nt+"px");return false}})})($);(function(A){A.ui.plugin.add("draggable","stop","effect",function(D,C){var B=C.helper;if(C.options.effect[1]){if(B!=this){C.options.beQuietAtEnd=true;switch(C.options.effect[1]){case"fade":A(B).fadeOut(300,function(){A(this).remove()});break;default:A(B).remove();break}}}});A.ui.plugin.add("draggable","start","effect",function(C,B){if(B.options.effect[0]){switch(B.options.effect[0]){case"fade":A(B.helper).hide().fadeIn(300);break}}});A.ui.plugin.add("draggable","start","cursor",function(D,C){var B=A("body");if(B.css("cursor")){C.options.ocursor=B.css("cursor")}B.css("cursor",C.options.cursor)});A.ui.plugin.add("draggable","stop","cursor",function(C,B){if(B.options.ocursor){A("body").css("cursor",B.options.ocursor)}});A.ui.plugin.add("draggable","start","zIndex",function(D,C){var B=A(C.helper);if(B.css("zIndex")){C.options.ozIndex=B.css("zIndex")}B.css("zIndex",C.options.zIndex)});A.ui.plugin.add("draggable","stop","zIndex",function(C,B){if(B.options.ozIndex){A(B.helper).css("zIndex",B.options.ozIndex)}});A.ui.plugin.add("draggable","start","opacity",function(D,C){var B=A(C.helper);if(B.css("opacity")){C.options.oopacity=B.css("opacity")}B.css("opacity",C.options.opacity)});A.ui.plugin.add("draggable","stop","opacity",function(C,B){if(B.options.oopacity){A(B.helper).css("opacity",B.options.oopacity)}});A.ui.plugin.add("draggable","stop","revert",function(F,E){var H=E.options;var G={left:0,top:0};H.beQuietAtEnd=true;if(E.helper!=this){G=A(E.draggable.sorthelper||this).offset({border:false});var B=G.left-H.po.left-H.margins.left;var D=G.top-H.po.top-H.margins.top}else{var B=H.co.left-(H.po?H.po.left:0);var D=H.co.top-(H.po?H.po.top:0)}var C=E.draggable;A(E.helper).animate({left:B,top:D},500,function(){if(H.wasPositioned){A(C.element).css("position",H.wasPositioned)}if(H.stop){H.stop.apply(C.element,[C.helper,C.pos,[H.co.left-H.po.left,H.co.top-H.po.top],C])}if(C.helper!=C.element){window.setTimeout(function(){A(C.helper).remove()},0)}})});A.ui.plugin.add("draggable","start","iframeFix",function(D,C){var F=C.options;if(!C.draggable.slowMode){if(F.iframeFix.constructor==Array){for(var B=0;B<F.iframeFix.length;B++){var E=A(F.iframeFix[B]).offset({border:false});A("<div class='DragDropIframeFix' style='background: #fff;'></div>").css("width",A(F.iframeFix[B])[0].offsetWidth+"px").css("height",A(F.iframeFix[B])[0].offsetHeight+"px").css("position","absolute").css("opacity","0.001").css("z-index","1000").css("top",E.top+"px").css("left",E.left+"px").appendTo("body")}}else{A("iframe").each(function(){var G=A(this).offset({border:false});A("<div class='DragDropIframeFix' style='background: #fff;'></div>").css("width",this.offsetWidth+"px").css("height",this.offsetHeight+"px").css("position","absolute").css("opacity","0.001").css("z-index","1000").css("top",G.top+"px").css("left",G.left+"px").appendTo("body")})}}});A.ui.plugin.add("draggable","stop","iframeFix",function(C,B){if(B.options.iframeFix){A("div.DragDropIframeFix").each(function(){this.parentNode.removeChild(this)})}});A.ui.plugin.add("draggable","start","containment",function(D,B){var F=B.options;if(!F.cursorAtIgnore||F.containment.left!=undefined||F.containment.constructor==Array){return }if(F.containment=="parent"){F.containment=this.parentNode}if(F.containment=="document"){F.containment=[0-F.margins.left,0-F.margins.top,A(document).width()-F.margins.right,(A(document).height()||document.body.parentNode.scrollHeight)-F.margins.bottom]}else{var C=A(F.containment)[0];var E=A(F.containment).offset({border:false});F.containment=[E.left-F.margins.left,E.top-F.margins.top,E.left+(C.offsetWidth||C.scrollWidth)-F.margins.right,E.top+(C.offsetHeight||C.scrollHeight)-F.margins.bottom]}});A.ui.plugin.add("draggable","drag","containment",function(E,C){var F=C.options;if(!F.cursorAtIgnore){return }var B=A(C.helper);var G=F.containment;if(G.constructor==Array){if((C.draggable.pos[0]<G[0]-F.po.left)){C.draggable.pos[0]=G[0]-F.po.left}if((C.draggable.pos[1]<G[1]-F.po.top)){C.draggable.pos[1]=G[1]-F.po.top}if(C.draggable.pos[0]+B[0].offsetWidth>G[2]-F.po.left){C.draggable.pos[0]=G[2]-F.po.left-B[0].offsetWidth}if(C.draggable.pos[1]+B[0].offsetHeight>G[3]-F.po.top){C.draggable.pos[1]=G[3]-F.po.top-B[0].offsetHeight}}else{if(G.left&&(C.draggable.pos[0]<G.left)){C.draggable.pos[0]=G.left}if(G.top&&(C.draggable.pos[1]<G.top)){C.draggable.pos[1]=G.top}var D=A(F.pp);if(G.right&&C.draggable.pos[0]+B[0].offsetWidth>D[0].offsetWidth-G.right){C.draggable.pos[0]=(D[0].offsetWidth-G.right)-B[0].offsetWidth}if(G.bottom&&C.draggable.pos[1]+B[0].offsetHeight>D[0].offsetHeight-G.bottom){C.draggable.pos[1]=(D[0].offsetHeight-G.bottom)-B[0].offsetHeight}}});A.ui.plugin.add("draggable","drag","grid",function(C,B){var D=B.options;if(!D.cursorAtIgnore){return }B.draggable.pos[0]=D.co.left+D.margins.left-D.po.left+Math.round((B.draggable.pos[0]-D.co.left-D.margins.left+D.po.left)/D.grid[0])*D.grid[0];B.draggable.pos[1]=D.co.top+D.margins.top-D.po.top+Math.round((B.draggable.pos[1]-D.co.top-D.margins.top+D.po.top)/D.grid[1])*D.grid[1]});A.ui.plugin.add("draggable","drag","axis",function(C,B){var D=B.options;if(!D.cursorAtIgnore){return }if(D.constraint){D.axis=D.constraint}D.axis?(D.axis=="x"?B.draggable.pos[1]=D.co.top-D.margins.top-D.po.top:B.draggable.pos[0]=D.co.left-D.margins.left-D.po.left):null});A.ui.plugin.add("draggable","drag","scroll",function(C,B){var D=B.options;D.scrollSensitivity=D.scrollSensitivity||20;D.scrollSpeed=D.scrollSpeed||20;if(D.pp&&D.ppOverflow){}else{if((B.draggable.rpos[1]-A(window).height())-A(document).scrollTop()>-D.scrollSensitivity){window.scrollBy(0,D.scrollSpeed)}if(B.draggable.rpos[1]-A(document).scrollTop()<D.scrollSensitivity){window.scrollBy(0,-D.scrollSpeed)}if((B.draggable.rpos[0]-A(window).width())-A(document).scrollLeft()>-D.scrollSensitivity){window.scrollBy(D.scrollSpeed,0)}if(B.draggable.rpos[0]-A(document).scrollLeft()<D.scrollSensitivity){window.scrollBy(-D.scrollSpeed,0)}}});A.ui.plugin.add("draggable","drag","wrapHelper",function(F,E){var H=E.options;if(H.cursorAtIgnore){return }var B=E.helper;if(!H.pp||!H.ppOverflow){var D=A(window).width()-(A.browser.mozilla?20:0);var I=A(document).scrollLeft();var C=A(window).height();var G=A(document).scrollTop()}else{var D=H.pp.offsetWidth+H.po.left-20;var I=H.pp.scrollLeft;var C=H.pp.offsetHeight+H.po.top-20;var G=H.pp.scrollTop}E.draggable.pos[0]-=((E.draggable.rpos[0]-H.cursorAt.left-D+B.offsetWidth+H.margins.right)-I>0||(E.draggable.rpos[0]-H.cursorAt.left+H.margins.left)-I<0)?(B.offsetWidth+H.margins.left+H.margins.right-H.cursorAt.left*2):0;E.draggable.pos[1]-=((E.draggable.rpos[1]-H.cursorAt.top-C+B.offsetHeight+H.margins.bottom)-G>0||(E.draggable.rpos[1]-H.cursorAt.top+H.margins.top)-G<0)?(B.offsetHeight+H.margins.top+H.margins.bottom-H.cursorAt.top*2):0})})(jQuery);(function($){$.extend($.expr[":"],{droppable:"(' '+a.className+' ').indexOf(' ui-droppable ')"});var methods="destroy,enable,disable".split(",");for(var i=0;i<methods.length;i++){var cur=methods[i],f;eval('f = function() { var a = arguments; return this.each(function() { if(jQuery(this).is(".ui-droppable")) jQuery.data(this, "ui-droppable")["'+cur+'"](a); }); }');$.fn["droppable"+cur.substr(0,1).toUpperCase()+cur.substr(1)]=f}$.fn.droppableInstance=function(){if($(this[0]).is(".ui-droppable")){return $.data(this[0],"ui-droppable")}return false};$.fn.droppable=function(o){return this.each(function(){new $.ui.droppable(this,o)})};$.ui.droppable=function(el,o){if(!o){var o={}}this.element=el;if($.browser.msie){el.droppable=1}$.data(el,"ui-droppable",this);this.options={};$.extend(this.options,o);var accept=o.accept;$.extend(this.options,{accept:o.accept&&o.accept.constructor==Function?o.accept:function(d){return $(d).is(accept)},tolerance:o.tolerance||"intersect"});o=this.options;var self=this;this.mouseBindings=[function(e){return self.move.apply(self,[e])},function(e){return self.drop.apply(self,[e])}];$(this.element).bind("mousemove",this.mouseBindings[0]);$(this.element).bind("mouseup",this.mouseBindings[1]);$.ui.ddmanager.droppables.push({item:this,over:0,out:1});$(this.element).addClass("ui-droppable")};$.extend($.ui.droppable.prototype,{plugins:{},prepareCallbackObj:function(c){return{draggable:c,droppable:this,element:c.element,helper:c.helper,options:this.options}},destroy:function(){$(this.element).removeClass("ui-droppable").removeClass("ui-droppable-disabled");$(this.element).unbind("mousemove",this.mouseBindings[0]);$(this.element).unbind("mouseup",this.mouseBindings[1]);for(var i=0;i<$.ui.ddmanager.droppables.length;i++){if($.ui.ddmanager.droppables[i].item==this){$.ui.ddmanager.droppables.splice(i,1)}}},enable:function(){$(this.element).removeClass("ui-droppable-disabled");this.disabled=false},disable:function(){$(this.element).addClass("ui-droppable-disabled");this.disabled=true},move:function(e){if(!$.ui.ddmanager.current){return }var o=this.options;var c=$.ui.ddmanager.current;var findCurrentTarget=function(e){if(e.currentTarget){return e.currentTarget}var el=e.srcElement;do{if(el.droppable){return el}el=el.parentNode}while(el)};if(c&&o.accept(c.element)){c.currentTarget=findCurrentTarget(e)}c.drag.apply(c,[e]);e.stopPropagation?e.stopPropagation():e.cancelBubble=true},over:function(e){var c=$.ui.ddmanager.current;if(!c||c.element==this.element){return }var o=this.options;if(o.accept(c.element)){$.ui.plugin.call(this,"over",[e,this.prepareCallbackObj(c)]);$(this.element).triggerHandler("dropover",[e,this.prepareCallbackObj(c)],o.over)}},out:function(e){var c=$.ui.ddmanager.current;if(!c||c.element==this.element){return }var o=this.options;if(o.accept(c.element)){$.ui.plugin.call(this,"out",[e,this.prepareCallbackObj(c)]);$(this.element).triggerHandler("dropout",[e,this.prepareCallbackObj(c)],o.out)}},drop:function(e){var c=$.ui.ddmanager.current;if(!c||c.element==this.element){return }var o=this.options;if(o.accept(c.element)){if(o.greedy&&!c.slowMode){if(c.currentTarget==this.element){$.ui.plugin.call(this,"drop",[e,{draggable:c,droppable:this,element:c.element,helper:c.helper}]);$(this.element).triggerHandler("drop",[e,{draggable:c,droppable:this,element:c.element,helper:c.helper}],o.drop)}}else{$.ui.plugin.call(this,"drop",[e,this.prepareCallbackObj(c)]);$(this.element).triggerHandler("drop",[e,this.prepareCallbackObj(c)],o.drop)}}},activate:function(e){var c=$.ui.ddmanager.current;$.ui.plugin.call(this,"activate",[e,this.prepareCallbackObj(c)]);if(c){$(this.element).triggerHandler("dropactivate",[e,this.prepareCallbackObj(c)],this.options.activate)}},deactivate:function(e){var c=$.ui.ddmanager.current;$.ui.plugin.call(this,"deactivate",[e,this.prepareCallbackObj(c)]);if(c){$(this.element).triggerHandler("dropdeactivate",[e,this.prepareCallbackObj(c)],this.options.deactivate)}}});$.ui.intersect=function(oDrag,oDrop,toleranceMode){if(!oDrop.offset){return false}var x1=oDrag.rpos[0]-oDrag.options.cursorAt.left+oDrag.options.margins.left,x2=x1+oDrag.helperSize.width,y1=oDrag.rpos[1]-oDrag.options.cursorAt.top+oDrag.options.margins.top,y2=y1+oDrag.helperSize.height;var l=oDrop.offset.left,r=l+oDrop.item.element.offsetWidth,t=oDrop.offset.top,b=t+oDrop.item.element.offsetHeight;switch(toleranceMode){case"fit":return(l<x1&&x2<r&&t<y1&&y2<b);break;case"intersect":return(l<x1+(oDrag.helperSize.width/2)&&x2-(oDrag.helperSize.width/2)<r&&t<y1+(oDrag.helperSize.height/2)&&y2-(oDrag.helperSize.height/2)<b);break;case"pointer":return(l<oDrag.rpos[0]&&oDrag.rpos[0]<r&&t<oDrag.rpos[1]&&oDrag.rpos[1]<b);break;case"touch":return((l<x1&&x1<r&&t<y1&&y1<b)||(l<x1&&x1<r&&t<y2&&y2<b)||(l<x2&&x2<r&&t<y1&&y1<b)||(l<x2&&x2<r&&t<y2&&y2<b));break;default:return false;break}}})($);(function(A){A.ui.plugin.add("droppable","activate","activeClass",function(C,B){A(this).addClass(B.options.activeClass)});A.ui.plugin.add("droppable","deactivate","activeClass",function(C,B){A(this).removeClass(B.options.activeClass)});A.ui.plugin.add("droppable","drop","activeClass",function(C,B){A(this).removeClass(B.options.activeClass)});A.ui.plugin.add("droppable","over","hoverClass",function(C,B){A(this).addClass(B.options.hoverClass)});A.ui.plugin.add("droppable","out","hoverClass",function(C,B){A(this).removeClass(B.options.hoverClass)});A.ui.plugin.add("droppable","drop","hoverClass",function(C,B){A(this).removeClass(B.options.hoverClass)})})(jQuery);(function($){$.extend($.expr[":"],{resizable:"(' '+a.className+' ').indexOf(' ui-resizable ')"});$.fn.resizable=function(o){return this.each(function(){if(!$(this).is(".ui-resizable")){new $.ui.resizable(this,o)}})};var methods="destroy,enable,disable".split(",");for(var i=0;i<methods.length;i++){var cur=methods[i],f;eval('f = function() { var a = arguments; return this.each(function() { if(jQuery(this).is(".ui-resizable")) jQuery.data(this, "ui-resizable")["'+cur+'"](a); if(jQuery(this.parentNode).is(".ui-resizable")) jQuery.data(this, "ui-resizable")["'+cur+'"](a); }); }');$.fn["resizable"+cur.substr(0,1).toUpperCase()+cur.substr(1)]=f}$.fn.resizableInstance=function(){if($(this[0]).is(".ui-resizable")||$(this[0].parentNode).is(".ui-resizable")){return $.data(this[0],"ui-resizable")}return false};$.ui.resizable=function(el,o){var options={};o=o||{};$.extend(options,o);this.element=el;var self=this;$.data(this.element,"ui-resizable",this);if(options.proxy){var helper=function(e,that){var helper=$("<div></div>").css({width:$(this).width(),height:$(this).height(),position:"absolute",left:that.options.co.left,top:that.options.co.top}).addClass(that.options.proxy);return helper}}else{var helper="original"}if(el.nodeName.match(/textarea|input|select|button|img/i)){options.destructive=true}if(options.destructive){$(el).wrap('<div class="ui-wrapper"  style="position: relative; width: '+$(el).outerWidth()+"px; height: "+$(el).outerHeight()+';"></div>');var oel=el;el=el.parentNode;this.element=el;$(el).css({marginLeft:$(oel).css("marginLeft"),marginTop:$(oel).css("marginTop"),marginRight:$(oel).css("marginRight"),marginBottom:$(oel).css("marginBottom")});$(oel).css({marginLeft:0,marginTop:0,marginRight:0,marginBottom:0});o.proportionallyResize=o.proportionallyResize||[];o.proportionallyResize.push(oel);var b=[parseInt($(oel).css("borderTopWidth")),parseInt($(oel).css("borderRightWidth")),parseInt($(oel).css("borderBottomWidth")),parseInt($(oel).css("borderLeftWidth"))]}else{var b=[0,0,0,0]}if(options.destructive||!$(".ui-resizable-handle",el).length){var t=function(a,b){$(el).append("<div class='ui-resizable-"+a+" ui-resizable-handle' style='"+b+"'></div>")};t("e","right: "+b[1]+"px;"+(options.zIndex?"z-index: "+options.zIndex+";":""));t("s","bottom: "+b[1]+"px;"+(options.zIndex?"z-index: "+options.zIndex+";":""));t("se","bottom: "+b[2]+"px; right: "+b[1]+"px;"+(options.zIndex?"z-index: "+options.zIndex+";":""))}options.modifyThese=[];if(o.proportionallyResize){options.proportionallyResize=o.proportionallyResize.slice(0);var propRes=options.proportionallyResize;for(var i in propRes){if(propRes[i].constructor==String){propRes[i]=$(propRes[i],el)}if(!$(propRes[i]).length){continue}var x=$(propRes[i]).width()-$(el).width();var y=$(propRes[i]).height()-$(el).height();options.modifyThese.push([$(propRes[i]),x,y])}}options.handles={};if(!o.handles){o.handles={n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}}for(var i in o.handles){options.handles[i]=o.handles[i]}for(var i in options.handles){if(options.handles[i].constructor==String){options.handles[i]=$(options.handles[i],el)}if(!$(options.handles[i]).length){continue}$(options.handles[i]).bind("mousedown",function(e){self.interaction.options.axis=this.resizeAxis})[0].resizeAxis=i}if(o.autohide){$(this.element).addClass("ui-resizable-autohide").hover(function(){$(this).removeClass("ui-resizable-autohide")},function(){if(self.interaction.options.autohide&&!self.interaction.init){$(this).addClass("ui-resizable-autohide")}})}$.extend(options,{helper:helper,nonDestructive:true,dragPrevention:"input,button,select",minHeight:options.minHeight||50,minWidth:options.minWidth||100,startCondition:function(e){if(self.disabled){return false}for(var i in options.handles){if($(options.handles[i])[0]==e.target){return true}}return false},_start:function(h,p,c,t,e){self.start.apply(t,[self,e])},_beforeStop:function(h,p,c,t,e){self.stop.apply(t,[self,e])},_drag:function(h,p,c,t,e){self.drag.apply(t,[self,e])}});this.interaction=new $.ui.mouseInteraction(el,options);$(this.element).addClass("ui-resizable")};$.extend($.ui.resizable.prototype,{plugins:{},prepareCallbackObj:function(self){return{helper:self.helper,resizable:self,axis:self.options.axis,options:self.options}},destroy:function(){$(this.element).removeClass("ui-resizable").removeClass("ui-resizable-disabled");this.interaction.destroy()},enable:function(){$(this.element).removeClass("ui-resizable-disabled");this.disabled=false},disable:function(){$(this.element).addClass("ui-resizable-disabled");this.disabled=true},start:function(that,e){this.options.originalSize=[$(this.element).width(),$(this.element).height()];this.options.originalPosition=$(this.element).css("position");this.options.originalPositionValues=$(this.element).position();this.options.modifyThese.push([$(this.helper),0,0]);$(that.element).triggerHandler("resizestart",[e,that.prepareCallbackObj(this)],this.options.start);return false},stop:function(that,e){var o=this.options;$(that.element).triggerHandler("resizestop",[e,that.prepareCallbackObj(this)],this.options.stop);if(o.proxy){$(this.element).css({width:$(this.helper).width(),height:$(this.helper).height()});if(o.originalPosition=="absolute"||o.originalPosition=="fixed"){$(this.element).css({top:$(this.helper).css("top"),left:$(this.helper).css("left")})}}return false},drag:function(that,e){var o=this.options;var rel=(o.originalPosition!="absolute"&&o.originalPosition!="fixed");var co=rel?o.co:this.options.originalPositionValues;var p=o.originalSize;this.pos=rel?[this.rpos[0]-o.cursorAt.left,this.rpos[1]-o.cursorAt.top]:[this.pos[0]-o.cursorAt.left,this.pos[1]-o.cursorAt.top];var nw=p[0]+(this.pos[0]-co.left);var nh=p[1]+(this.pos[1]-co.top);if(o.axis){switch(o.axis){case"e":nh=p[1];break;case"s":nw=p[0];break;case"n":case"ne":if(!o.proxy&&(o.originalPosition!="absolute"&&o.originalPosition!="fixed")){return false}if(o.axis=="n"){nw=p[0]}var mod=(this.pos[1]-co.top);nh=nh-(mod*2);mod=nh<=o.minHeight?p[1]-o.minHeight:(nh>=o.maxHeight?0-(o.maxHeight-p[1]):mod);$(this.helper).css("top",co.top+mod);break;case"w":case"sw":if(!o.proxy&&(o.originalPosition!="absolute"&&o.originalPosition!="fixed")){return false}if(o.axis=="w"){nh=p[1]}var mod=(this.pos[0]-co.left);nw=nw-(mod*2);mod=nw<=o.minWidth?p[0]-o.minWidth:(nw>=o.maxWidth?0-(o.maxWidth-p[0]):mod);$(this.helper).css("left",co.left+mod);break;case"nw":if(!o.proxy&&(o.originalPosition!="absolute"&&o.originalPosition!="fixed")){return false}var modx=(this.pos[0]-co.left);nw=nw-(modx*2);modx=nw<=o.minWidth?p[0]-o.minWidth:(nw>=o.maxWidth?0-(o.maxWidth-p[0]):modx);var mody=(this.pos[1]-co.top);nh=nh-(mody*2);mody=nh<=o.minHeight?p[1]-o.minHeight:(nh>=o.maxHeight?0-(o.maxHeight-p[1]):mody);$(this.helper).css({left:co.left+modx,top:co.top+mody});break}}if(e.shiftKey){nh=nw*(p[1]/p[0])}if(o.minWidth){nw=nw<=o.minWidth?o.minWidth:nw}if(o.minHeight){nh=nh<=o.minHeight?o.minHeight:nh}if(o.maxWidth){nw=nw>=o.maxWidth?o.maxWidth:nw}if(o.maxHeight){nh=nh>=o.maxHeight?o.maxHeight:nh}if(e.shiftKey){nh=nw*(p[1]/p[0])}var modifier=$(that.element).triggerHandler("resize",[e,that.prepareCallbackObj(this)],o.resize);if(!modifier){modifier={}}for(var i in this.options.modifyThese){var c=this.options.modifyThese[i];c[0].css({width:modifier.width?modifier.width+c[1]:nw+c[1],height:modifier.height?modifier.height+c[2]:nh+c[2]})}return false}})})($);(function(A){A.ui=A.ui||{};A.fn.dialog=function(B){return this.each(function(){if(!A(this).is(".ui-dialog")){new A.ui.dialog(this,B)}})};A.fn.dialogOpen=function(){return this.each(function(){var B;if(A(this).parents(".ui-dialog").length){B=this}if(!B&&A(this).is(".ui-dialog")){B=A(".ui-dialog-content",this)[0]}A.ui.dialogOpen(B)})};A.fn.dialogClose=function(){return this.each(function(){var B;if(A(this).parents(".ui-dialog").length){B=this}if(!B&&A(this).is(".ui-dialog")){B=A(".ui-dialog-content",this)[0]}A.ui.dialogClose(B)})};A.ui.dialog=function(D,B){var L={width:300,height:200,position:"center",buttons:[],modal:false,drag:true,resize:true,shadow:false};var B=B||{};A.extend(L,B);this.element=D;var K=this;A.data(this.element,"ui-dialog",this);var E=A(D).addClass("ui-dialog-content").wrap(document.createElement("div")).wrap(document.createElement("div"));var H=E.parent().addClass("ui-dialog-container").css({position:"relative"});var J=H.parent().addClass("ui-dialog").addClass(E.attr("className")).css({position:"absolute",width:L.width,height:L.height});if(L.modal==false&&L.resize==true){J.append("<div class='ui-resizable-n ui-resizable-handle'></div>").append("<div class='ui-resizable-s ui-resizable-handle'></div>").append("<div class='ui-resizable-e ui-resizable-handle'></div>").append("<div class='ui-resizable-w ui-resizable-handle'></div>").append("<div class='ui-resizable-ne ui-resizable-handle'></div>").append("<div class='ui-resizable-se ui-resizable-handle'></div>").append("<div class='ui-resizable-sw ui-resizable-handle'></div>").append("<div class='ui-resizable-nw ui-resizable-handle'></div>");J.resizable()}H.prepend('<div class="ui-dialog-titlebar"></div>');var C=A(".ui-dialog-titlebar",H);var I=(L.title)?L.title:(E.attr("title"))?E.attr("title"):"";C.append('<span class="ui-dialog-title">'+I+"</span>");C.append('<div class="ui-dialog-titlebar-close"></div>');A(".ui-dialog-titlebar-close",C).hover(function(){A(this).addClass("ui-dialog-titlebar-close-hover")},function(){A(this).removeClass("ui-dialog-titlebar-close-hover")}).mousedown(function(M){M.stopPropagation()}).click(function(){K.close()});var F=0;A.each(L.buttons,function(){F=1;return false});if(F==1){J.append('<div class="ui-dialog-buttonpane"></div>');var G=A(".ui-dialog-buttonpane",J);A.each(L.buttons,function(M,O){var N=A(document.createElement("button")).text(M).click(O);G.append(N)})}if(L.modal==false&&L.drag==true){J.draggable({handle:".ui-dialog-titlebar"})}this.open=function(){var M=A(window),O=0,N=0;switch(L.position){case"center":O=(M.height()/2)-(J.height()/2);N=(M.width()/2)-(J.width()/2);break;case"left":O=(M.height()/2)-(J.height()/2);N=0;break;case"top":O=0;N=(M.width()/2)-(J.width()/2);break}J.css({top:O,left:N});J.appendTo("body").show()};this.close=function(){J.hide()};J.show();this.open();if(L.shadow&&A.fn.shadow!=undefined){J.shadow()}};A.ui.dialogOpen=function(B){A.data(B,"ui-dialog").open()};A.ui.dialogClose=function(B){A.data(B,"ui-dialog").close()}})(jQuery);(function(A){A.ui=A.ui||{};A.ui.accordion={};A.extend(A.ui.accordion,{defaults:{selectedClass:"selected",alwaysOpen:true,animated:"slide",event:"click",header:"a"},animations:{slide:function(B,D){B=A.extend({easing:"swing",duration:300},B,D);if(!B.toHide.size()){B.toShow.animate({height:"show"},{duration:B.duration,easing:B.easing,complete:B.finished});return }var C=B.toHide.height(),E=B.toShow.height(),F=E/C;B.toShow.css({height:0,overflow:"hidden"}).show();B.toHide.filter(":hidden").each(B.finished).end().filter(":visible").animate({height:"hide"},{step:function(G){B.toShow.height(Math.ceil((C-(G))*F))},duration:B.duration,easing:B.easing,complete:B.finished})},bounceslide:function(B){this.slide(B,{easing:B.down?"bounceout":"swing",duration:B.down?1000:200})},easeslide:function(B){this.slide(B,{easing:"easeinout",duration:700})}}});A.fn.extend({nextUntil:function(C){var B=[];this.each(function(){for(var D=this.nextSibling;D;D=D.nextSibling){if(D.nodeType!=1){continue}if(A.filter(C,[D]).r.length){break}B.push(D)}});return this.pushStack(B)},accordion:function(F){if(!this.length){return this}F=A.extend({},A.ui.accordion.defaults,F);if(F.navigation){var I=this.find("a").filter(function(){return this.href==location.href});if(I.length){if(I.filter(F.header).length){F.active=I}else{F.active=I.parent().parent().prev();I.addClass("current")}}}var B=this,D=B.find(F.header),E=C(F.active),H=0;if(F.fillSpace){var L=this.parent().height();D.each(function(){L-=A(this).outerHeight()});var K=0;D.nextUntil(F.header).each(function(){K=Math.max(K,A(this).innerHeight()-A(this).height())}).height(L-K)}else{if(F.autoheight){var L=0;D.nextUntil(F.header).each(function(){L=Math.max(L,A(this).height())}).height(L)}}D.not(E||"").nextUntil(F.header).hide();E.parent().andSelf().addClass(F.selectedClass);function C(N){return N!=undefined?typeof N=="number"?D.filter(":eq("+N+")"):D.not(D.not(N)):N===false?A("<div>"):D.filter(":eq(0)")}function G(N,P,Q,O,S){var R=function(T){H=T?0:--H;if(H){return }B.trigger("change",Q)};H=P.size()==0?N.size():P.size();if(F.animated){if(!F.alwaysOpen&&O){N.slideToggle(F.animated);R(true)}else{A.ui.accordion.animations[F.animated]({toShow:N,toHide:P,finished:R,down:S})}}else{if(!F.alwaysOpen&&O){N.toggle()}else{P.hide();N.show()}R(true)}}function J(R){if(!R.target&&!F.alwaysOpen){E.toggleClass(F.selectedClass);var P=E.nextUntil(F.header);var N=E=A([]);G(N,P);return }var Q=A(R.target);if(Q.parents(F.header).length){while(!Q.is(F.header)){Q=Q.parent()}}var O=Q[0]==E[0];if(H||(F.alwaysOpen&&O)||!Q.is(F.header)){return }E.parent().andSelf().toggleClass(F.selectedClass);if(!O){Q.parent().andSelf().addClass(F.selectedClass)}var N=Q.nextUntil(F.header),P=E.nextUntil(F.header),S=[Q,E,N,P],T=D.index(E[0])>D.index(Q[0]);E=O?A([]):Q;G(N,P,S,O,T);return !N.length}function M(O,N){if(arguments.length==1){return }J({target:C(N)[0]})}return B.bind(F.event,J).bind("activate",M)},activate:function(B){return this.trigger("activate",[B])}})})(jQuery);(function($){function PopUpCal(){this._nextId=0;this._inst=[];this._curInst=null;this._disabledInputs=[];this._popUpShowing=false;this._inDialog=false;this.regional=[];this.regional[""]={clearText:"Clear",closeText:"Close",prevText:"&lt;Prev",nextText:"Next&gt;",currentText:"Today",dayNames:["Su","Mo","Tu","We","Th","Fr","Sa"],monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],dateFormat:"DMY/"};this._defaults={autoPopUp:"focus",defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:false,closeAtTop:true,hideIfNoPrevNext:false,changeMonth:true,changeYear:true,yearRange:"-10:+10",firstDay:0,changeFirstDay:true,showOtherMonths:false,minDate:null,maxDate:null,speed:"medium",customDate:null,fieldSettings:null,onSelect:null};$.extend(this._defaults,this.regional[""]);this._calendarDiv=$('<div id="calendar_div"></div>');$(document.body).append(this._calendarDiv);$(document.body).mousedown(this._checkExternalClick)}$.extend(PopUpCal.prototype,{markerClassName:"hasCalendar",_register:function(inst){var id=this._nextId++;this._inst[id]=inst;return id},_getInst:function(id){return this._inst[id]||id},setDefaults:function(settings){extendRemove(this._defaults,settings||{})},_doKeyDown:function(e){var inst=popUpCal._getInst(this._calId);if(popUpCal._popUpShowing){switch(e.keyCode){case 9:popUpCal.hideCalendar(inst,"");break;case 13:popUpCal._selectDate(inst);break;case 27:popUpCal.hideCalendar(inst,inst._get("speed"));break;case 33:popUpCal._adjustDate(inst,-1,(e.ctrlKey?"Y":"M"));break;case 34:popUpCal._adjustDate(inst,+1,(e.ctrlKey?"Y":"M"));break;case 35:if(e.ctrlKey){popUpCal._clearDate(inst)}break;case 36:if(e.ctrlKey){popUpCal._gotoToday(inst)}break;case 37:if(e.ctrlKey){popUpCal._adjustDate(inst,-1,"D")}break;case 38:if(e.ctrlKey){popUpCal._adjustDate(inst,-7,"D")}break;case 39:if(e.ctrlKey){popUpCal._adjustDate(inst,+1,"D")}break;case 40:if(e.ctrlKey){popUpCal._adjustDate(inst,+7,"D")}break}}else{if(e.keyCode==36&&e.ctrlKey){popUpCal.showFor(this)}}},_doKeyPress:function(e){var inst=popUpCal._getInst(this._calId);var chr=String.fromCharCode(e.charCode==undefined?e.keyCode:e.charCode);return(chr<" "||chr==inst._get("dateFormat").charAt(3)||(chr>="0"&&chr<="9"))},_connectCalendar:function(target,inst){var input=$(target);if(this._hasClass(input,this.markerClassName)){return }var appendText=inst._get("appendText");if(appendText){input.after('<span class="calendar_append">'+appendText+"</span>")}var autoPopUp=inst._get("autoPopUp");if(autoPopUp=="focus"||autoPopUp=="both"){input.focus(this.showFor)}if(autoPopUp=="button"||autoPopUp=="both"){var buttonText=inst._get("buttonText");var buttonImage=inst._get("buttonImage");var buttonImageOnly=inst._get("buttonImageOnly");var trigger=$(buttonImageOnly?'<img class="calendar_trigger" src="'+buttonImage+'" alt="'+buttonText+'" title="'+buttonText+'"/>':'<button type="button" class="calendar_trigger">'+(buttonImage!=""?'<img src="'+buttonImage+'" alt="'+buttonText+'" title="'+buttonText+'"/>':buttonText)+"</button>");input.wrap('<span class="calendar_wrap"></span>').after(trigger);trigger.click(this.showFor)}input.addClass(this.markerClassName).keydown(this._doKeyDown).keypress(this._doKeyPress);input[0]._calId=inst._id},_inlineCalendar:function(target,inst){var input=$(target);if(this._hasClass(input,this.markerClassName)){return }input.addClass(this.markerClassName).append(inst._calendarDiv);input[0]._calId=inst._id},_hasClass:function(element,className){var classes=element.attr("class");return(classes&&classes.indexOf(className)>-1)},dialogCalendar:function(dateText,onSelect,settings,pos){var inst=this._dialogInst;if(!inst){inst=this._dialogInst=new PopUpCalInstance({},false);this._dialogInput=$('<input type="text" size="1" style="position: absolute; top: -100px;"/>');this._dialogInput.keydown(this._doKeyDown);$("body").append(this._dialogInput);this._dialogInput[0]._calId=inst._id}extendRemove(inst._settings,settings||{});this._dialogInput.val(dateText);if(self.innerHeight){windowWidth=self.innerWidth;windowHeight=self.innerHeight}else{if(document.documentElement&&document.documentElement.clientHeight){windowWidth=document.documentElement.clientWidth;windowHeight=document.documentElement.clientHeight}else{if(document.body){windowWidth=document.body.clientWidth;windowHeight=document.body.clientHeight}}}this._pos=pos||[(windowWidth/2)-100,(windowHeight/2)-100];this._dialogInput.css("left",this._pos[0]+"px").css("top",this._pos[1]+"px");inst._settings.onSelect=onSelect;this._inDialog=true;this._calendarDiv.addClass("calendar_dialog");this.showFor(this._dialogInput[0]);if($.blockUI){$.blockUI(this._calendarDiv)}},enableFor:function(inputs){inputs=(inputs.jquery?inputs:$(inputs));inputs.each(function(){this.disabled=false;$("../button.calendar_trigger",this).each(function(){this.disabled=false});$("../img.calendar_trigger",this).css({opacity:"1.0",cursor:""});var $this=this;popUpCal._disabledInputs=$.map(popUpCal._disabledInputs,function(value){return(value==$this?null:value)})})},disableFor:function(inputs){inputs=(inputs.jquery?inputs:$(inputs));inputs.each(function(){this.disabled=true;$("../button.calendar_trigger",this).each(function(){this.disabled=true});$("../img.calendar_trigger",this).css({opacity:"0.5",cursor:"default"});var $this=this;popUpCal._disabledInputs=$.map(popUpCal._disabledInputs,function(value){return(value==$this?null:value)});popUpCal._disabledInputs[popUpCal._disabledInputs.length]=this})},reconfigureFor:function(control,settings){control=(typeof control=="string"?$(control)[0]:control);var inst=this._getInst(control._calId);if(inst){extendRemove(inst._settings,settings||{});this._updateCalendar(inst)}},setDateFor:function(control,date){var inst=this._getInst(control._calId);if(inst){inst._setDate(date)}},getDateFor:function(control){var inst=this._getInst(control._calId);return(inst?inst._getDate():null)},showFor:function(target){var input=(target.nodeName&&target.nodeName.toLowerCase()=="input"?target:this);if(input.nodeName.toLowerCase()!="input"){input=$("input",input.parentNode)[0]}if(popUpCal._lastInput==input){return }for(var i=0;i<popUpCal._disabledInputs.length;i++){if(popUpCal._disabledInputs[i]==input){return }}var inst=popUpCal._getInst(input._calId);var fieldSettings=inst._get("fieldSettings");extendRemove(inst._settings,(fieldSettings?fieldSettings(input):{}));popUpCal.hideCalendar(inst,"");popUpCal._lastInput=input;inst._setDateFromField(input);if(popUpCal._inDialog){input.value=""}if(!popUpCal._pos){popUpCal._pos=popUpCal._findPos(input);popUpCal._pos[1]+=input.offsetHeight}inst._calendarDiv.css("position",(popUpCal._inDialog&&$.blockUI?"static":"absolute")).css("left",popUpCal._pos[0]+"px").css("top",popUpCal._pos[1]+"px");popUpCal._pos=null;popUpCal._showCalendar(inst)},_showCalendar:function(id){var inst=this._getInst(id);popUpCal._updateCalendar(inst);if(!inst._inline){var speed=inst._get("speed");inst._calendarDiv.show(speed,function(){popUpCal._popUpShowing=true;popUpCal._afterShow(inst)});if(speed==""){popUpCal._popUpShowing=true;popUpCal._afterShow(inst)}if(inst._input[0].type!="hidden"){inst._input[0].focus()}this._curInst=inst}},_updateCalendar:function(inst){inst._calendarDiv.empty().append(inst._generateCalendar());if(inst._input&&inst._input[0].type!="hidden"){inst._input[0].focus()}},_afterShow:function(inst){if($.browser.msie){$("#calendar_cover").css({width:inst._calendarDiv[0].offsetWidth+4,height:inst._calendarDiv[0].offsetHeight+4})}var calDiv=inst._calendarDiv[0];var pos=popUpCal._findPos(inst._input[0]);if(typeof (window.innerWidth)=="number"){browserWidth=window.innerWidth}else{browserWidth=document.documentElement.clientWidth}if(document.documentElement&&(document.documentElement.scrollLeft)){browserX=document.documentElement.scrollLeft}else{browserX=document.body.scrollLeft}if((calDiv.offsetLeft+calDiv.offsetWidth)>(browserWidth+browserX)){inst._calendarDiv.css("left",(pos[0]+inst._input[0].offsetWidth-calDiv.offsetWidth)+"px")}if(typeof (window.innerHeight)=="number"){browserHeight=window.innerHeight}else{browserHeight=document.documentElement.clientHeight}if(document.documentElement&&(document.documentElement.scrollTop)){browserTopY=document.documentElement.scrollTop}else{browserTopY=document.body.scrollTop}if((calDiv.offsetTop+calDiv.offsetHeight)>(browserTopY+browserHeight)){inst._calendarDiv.css("top",(pos[1]-calDiv.offsetHeight)+"px")}},hideCalendar:function(id,speed){var inst=this._getInst(id);if(popUpCal._popUpShowing){speed=(speed!=null?speed:inst._get("speed"));inst._calendarDiv.hide(speed,function(){popUpCal._tidyDialog(inst)});if(speed==""){popUpCal._tidyDialog(inst)}popUpCal._popUpShowing=false;popUpCal._lastInput=null;inst._settings.prompt=null;if(popUpCal._inDialog){popUpCal._dialogInput.css("position","absolute").css("left","0px").css("top","-100px");if($.blockUI){$.unblockUI();$("body").append(this._calendarDiv)}}popUpCal._inDialog=false}popUpCal._curInst=null},_tidyDialog:function(inst){inst._calendarDiv.removeClass("calendar_dialog");$(".calendar_prompt",inst._calendarDiv).remove()},_checkExternalClick:function(event){if(!popUpCal._curInst){return }var target=$(event.target);if((target.parents("#calendar_div").length==0)&&(target.attr("class")!="calendar_trigger")&&popUpCal._popUpShowing&&!(popUpCal._inDialog&&$.blockUI)){popUpCal.hideCalendar(popUpCal._curInst,"")}},_adjustDate:function(id,offset,period){var inst=this._getInst(id);inst._adjustDate(offset,period);this._updateCalendar(inst)},_gotoToday:function(id){var date=new Date();var inst=this._getInst(id);inst._selectedDay=date.getDate();inst._selectedMonth=date.getMonth();inst._selectedYear=date.getFullYear();this._adjustDate(inst)},_selectMonthYear:function(id,select,period){var inst=this._getInst(id);inst._selectingMonthYear=false;inst[period=="M"?"_selectedMonth":"_selectedYear"]=select.options[select.selectedIndex].value-0;this._adjustDate(inst)},_clickMonthYear:function(id){var inst=this._getInst(id);if(inst._input&&inst._selectingMonthYear&&!$.browser.msie){inst._input[0].focus()}inst._selectingMonthYear=!inst._selectingMonthYear},_changeFirstDay:function(id,a){var inst=this._getInst(id);var dayNames=inst._get("dayNames");var value=a.firstChild.nodeValue;for(var i=0;i<7;i++){if(dayNames[i]==value){inst._settings.firstDay=i;break}}this._updateCalendar(inst)},_selectDay:function(id,td){var inst=this._getInst(id);inst._selectedDay=$("a",td).html();this._selectDate(id)},_clearDate:function(id){this._selectDate(id,"")},_selectDate:function(id,dateStr){var inst=this._getInst(id);dateStr=(dateStr!=null?dateStr:inst._formatDate());if(inst._input){inst._input.val(dateStr)}var onSelect=inst._get("onSelect");if(onSelect){onSelect(dateStr,inst)}else{inst._input.trigger("change")}if(inst._inline){this._updateCalendar(inst)}else{this.hideCalendar(inst,inst._get("speed"))}},noWeekends:function(date){var day=date.getDay();return[(day>0&&day<6),""]},_findPos:function(obj){while(obj&&(obj.type=="hidden"||obj.nodeType!=1)){obj=obj.nextSibling}var curleft=curtop=0;if(obj&&obj.offsetParent){curleft=obj.offsetLeft;curtop=obj.offsetTop;while(obj=obj.offsetParent){var origcurleft=curleft;curleft+=obj.offsetLeft;if(curleft<0){curleft=origcurleft}curtop+=obj.offsetTop}}return[curleft,curtop]}});function PopUpCalInstance(settings,inline){this._id=popUpCal._register(this);this._selectedDay=0;this._selectedMonth=0;this._selectedYear=0;this._input=null;this._inline=inline;this._calendarDiv=(!inline?popUpCal._calendarDiv:$('<div id="calendar_div_'+this._id+'" class="calendar_inline"></div>'));this._settings=extendRemove({},settings||{});if(inline){this._setDate(this._getDefaultDate())}}$.extend(PopUpCalInstance.prototype,{_get:function(name){return(this._settings[name]!=null?this._settings[name]:popUpCal._defaults[name])},_setDateFromField:function(input){this._input=$(input);var dateFormat=this._get("dateFormat");var currentDate=this._input.val().split(dateFormat.charAt(3));if(currentDate.length==3){this._currentDay=parseInt(currentDate[dateFormat.indexOf("D")],10);this._currentMonth=parseInt(currentDate[dateFormat.indexOf("M")],10)-1;this._currentYear=parseInt(currentDate[dateFormat.indexOf("Y")],10)}else{var date=this._getDefaultDate();this._currentDay=date.getDate();this._currentMonth=date.getMonth();this._currentYear=date.getFullYear()}this._selectedDay=this._currentDay;this._selectedMonth=this._currentMonth;this._selectedYear=this._currentYear;this._adjustDate()},_getDefaultDate:function(){var offsetDate=function(offset){var date=new Date();date.setDate(date.getDate()+offset);return date};var defaultDate=this._get("defaultDate");return(defaultDate==null?new Date():(typeof defaultDate=="number"?offsetDate(defaultDate):defaultDate))},_setDate:function(date){this._selectedDay=this._currentDay=date.getDate();this._selectedMonth=this._currentMonth=date.getMonth();this._selectedYear=this._currentYear=date.getFullYear();this._adjustDate()},_getDate:function(){return new Date(this._currentYear,this._currentMonth,this._currentDay)},_generateCalendar:function(){var today=new Date();today=new Date(today.getFullYear(),today.getMonth(),today.getDate());var controls='<div class="calendar_control"><a class="calendar_clear" onclick="popUpCal._clearDate('+this._id+');">'+this._get("clearText")+'</a><a class="calendar_close" onclick="popUpCal.hideCalendar('+this._id+');">'+this._get("closeText")+"</a></div>";var prompt=this._get("prompt");var closeAtTop=this._get("closeAtTop");var hideIfNoPrevNext=this._get("hideIfNoPrevNext");var html=(prompt?'<div class="calendar_prompt">'+prompt+"</div>":"")+(closeAtTop&&!this._inline?controls:"")+'<div class="calendar_links">'+(this._canAdjustMonth(-1)?'<a class="calendar_prev" onclick="popUpCal._adjustDate('+this._id+", -1, 'M');\">"+this._get("prevText")+"</a>":(hideIfNoPrevNext?"":'<label class="calendar_prev">'+this._get("prevText")+"</label>"))+(this._isInRange(today)?'<a class="calendar_current" onclick="popUpCal._gotoToday('+this._id+');">'+this._get("currentText")+"</a>":"")+(this._canAdjustMonth(+1)?'<a class="calendar_next" onclick="popUpCal._adjustDate('+this._id+", +1, 'M');\">"+this._get("nextText")+"</a>":(hideIfNoPrevNext?"":'<label class="calendar_next">'+this._get("nextText")+"</label>"))+'</div><div class="calendar_header">';var minDate=this._get("minDate");var maxDate=this._get("maxDate");var monthNames=this._get("monthNames");if(!this._get("changeMonth")){html+=monthNames[this._selectedMonth]+"&nbsp;"}else{var inMinYear=(minDate&&minDate.getFullYear()==this._selectedYear);var inMaxYear=(maxDate&&maxDate.getFullYear()==this._selectedYear);html+='<select class="calendar_newMonth" onchange="popUpCal._selectMonthYear('+this._id+", this, 'M');\" onclick=\"popUpCal._clickMonthYear("+this._id+');">';for(var month=0;month<12;month++){if((!inMinYear||month>=minDate.getMonth())&&(!inMaxYear||month<=maxDate.getMonth())){html+='<option value="'+month+'"'+(month==this._selectedMonth?' selected="selected"':"")+">"+monthNames[month]+"</option>"}}html+="</select>"}if(!this._get("changeYear")){html+=this._selectedYear}else{var years=this._get("yearRange").split(":");var year=0;var endYear=0;if(years.length!=2){year=this._selectedYear-10;endYear=this._selectedYear+10}else{if(years[0].charAt(0)=="+"||years[0].charAt(0)=="-"){year=this._selectedYear+parseInt(years[0],10);endYear=this._selectedYear+parseInt(years[1],10)}else{year=parseInt(years[0],10);endYear=parseInt(years[1],10)}}year=(minDate?Math.max(year,minDate.getFullYear()):year);endYear=(maxDate?Math.min(endYear,maxDate.getFullYear()):endYear);html+='<select class="calendar_newYear" onchange="popUpCal._selectMonthYear('+this._id+", this, 'Y');\" onclick=\"popUpCal._clickMonthYear("+this._id+');">';for(;year<=endYear;year++){html+='<option value="'+year+'"'+(year==this._selectedYear?' selected="selected"':"")+">"+year+"</option>"}html+="</select>"}html+='</div><table class="calendar" cellpadding="0" cellspacing="0"><thead><tr class="calendar_titleRow">';var firstDay=this._get("firstDay");var changeFirstDay=this._get("changeFirstDay");var dayNames=this._get("dayNames");for(var dow=0;dow<7;dow++){html+="<td>"+(!changeFirstDay?"":'<a onclick="popUpCal._changeFirstDay('+this._id+', this);">')+dayNames[(dow+firstDay)%7]+(changeFirstDay?"</a>":"")+"</td>"}html+="</tr></thead><tbody>";var daysInMonth=this._getDaysInMonth(this._selectedYear,this._selectedMonth);this._selectedDay=Math.min(this._selectedDay,daysInMonth);var leadDays=(this._getFirstDayOfMonth(this._selectedYear,this._selectedMonth)-firstDay+7)%7;var currentDate=new Date(this._currentYear,this._currentMonth,this._currentDay);var selectedDate=new Date(this._selectedYear,this._selectedMonth,this._selectedDay);var printDate=new Date(this._selectedYear,this._selectedMonth,1-leadDays);var numRows=Math.ceil((leadDays+daysInMonth)/7);var customDate=this._get("customDate");var showOtherMonths=this._get("showOtherMonths");for(var row=0;row<numRows;row++){html+='<tr class="calendar_daysRow">';for(var dow=0;dow<7;dow++){var customSettings=(customDate?customDate(printDate):[true,""]);var otherMonth=(printDate.getMonth()!=this._selectedMonth);var unselectable=otherMonth||!customSettings[0]||(minDate&&printDate<minDate)||(maxDate&&printDate>maxDate);html+='<td class="calendar_daysCell'+((dow+firstDay+6)%7>=5?" calendar_weekEndCell":"")+(otherMonth?" calendar_otherMonth":"")+(printDate.getTime()==selectedDate.getTime()?" calendar_daysCellOver":"")+(unselectable?" calendar_unselectable":"")+(otherMonth&&!showOtherMonths?"":" "+customSettings[1]+(printDate.getTime()==currentDate.getTime()?" calendar_currentDay":(printDate.getTime()==today.getTime()?" calendar_today":"")))+'"'+(unselectable?"":' onmouseover="$ui(this).addClass(\'calendar_daysCellOver\');" onmouseout="$ui(this).removeClass(\'calendar_daysCellOver\');" onclick="popUpCal._selectDay('+this._id+', this);"')+">"+(otherMonth?(showOtherMonths?printDate.getDate():"&nbsp;"):(unselectable?printDate.getDate():"<a>"+printDate.getDate()+"</a>"))+"</td>";printDate.setDate(printDate.getDate()+1)}html+="</tr>"}html+="</tbody></table>"+(!closeAtTop&&!this._inline?controls:"")+'<div style="clear: both;"></div>'+(!$.browser.msie?"":'<!--[if lte IE 6.5]><iframe src="javascript:false;" class="calendar_cover"></iframe><![endif]-->');return html},_adjustDate:function(offset,period){var date=new Date(this._selectedYear+(period=="Y"?offset:0),this._selectedMonth+(period=="M"?offset:0),this._selectedDay+(period=="D"?offset:0));var minDate=this._get("minDate");var maxDate=this._get("maxDate");date=(minDate&&date<minDate?minDate:date);date=(maxDate&&date>maxDate?maxDate:date);this._selectedDay=date.getDate();this._selectedMonth=date.getMonth();this._selectedYear=date.getFullYear()},_getDaysInMonth:function(year,month){return 32-new Date(year,month,32).getDate()},_getFirstDayOfMonth:function(year,month){return new Date(year,month,1).getDay()},_canAdjustMonth:function(offset){var date=new Date(this._selectedYear,this._selectedMonth+offset,1);if(offset<0){date.setDate(this._getDaysInMonth(date.getFullYear(),date.getMonth()))}return this._isInRange(date)},_isInRange:function(date){var minDate=this._get("minDate");var maxDate=this._get("maxDate");return((!minDate||date>=minDate)&&(!maxDate||date<=maxDate))},_formatDate:function(){var day=this._currentDay=this._selectedDay;var month=this._currentMonth=this._selectedMonth;var year=this._currentYear=this._selectedYear;month++;var dateFormat=this._get("dateFormat");var dateString="";for(var i=0;i<3;i++){dateString+=dateFormat.charAt(3)+(dateFormat.charAt(i)=="D"?(day<10?"0":"")+day:(dateFormat.charAt(i)=="M"?(month<10?"0":"")+month:(dateFormat.charAt(i)=="Y"?year:"?")))}return dateString.substring(dateFormat.charAt(3)?1:0)}});function extendRemove(target,props){$.extend(target,props);for(var name in props){if(props[name]==null){target[name]=null}}return target}$.fn.calendar=function(settings){return this.each(function(){var inlineSettings=null;for(attrName in popUpCal._defaults){var attrValue=this.getAttribute("cal:"+attrName);if(attrValue){inlineSettings=inlineSettings||{};try{inlineSettings[attrName]=eval(attrValue)}catch(err){inlineSettings[attrName]=attrValue}}}var nodeName=this.nodeName.toLowerCase();if(nodeName=="input"){var instSettings=(inlineSettings?$.extend($.extend({},settings||{}),inlineSettings||{}):settings);var inst=(inst&&!inlineSettings?inst:new PopUpCalInstance(instSettings,false));popUpCal._connectCalendar(this,inst)}else{if(nodeName=="div"||nodeName=="span"){var instSettings=$.extend($.extend({},settings||{}),inlineSettings||{});var inst=new PopUpCalInstance(instSettings,true);popUpCal._inlineCalendar(this,inst)}}})};$(document).ready(function(){popUpCal=new PopUpCal()})})($);(function($){$.ui=$.ui||{};$.extend($.expr[":"],{magnifier:"(' '+a.className+' ').indexOf(' ui-magnifier ')"});var methods="destroy,enable,disable,reset".split(",");for(var i=0;i<methods.length;i++){var cur=methods[i],f;eval('f = function() { var a = arguments; return this.each(function() { if(jQuery(this).is(".ui-magnifier")) jQuery.data(this, "ui-magnifier")["'+cur+'"](a); }); }');$.fn["magnifier"+cur.substr(0,1).toUpperCase()+cur.substr(1)]=f}$.fn.magnifierInstance=function(){if($(this[0]).is(".ui-magnifier")){return $.data(this[0],"ui-magnifier")}return false};$.fn.magnifier=function(options){return this.each(function(){new $.ui.magnifier(this,options)})};$.ui.magnifier=function(el,options){var self=this;this.items=[];this.element=el;this.options=options||{};var o=this.options;$.data(el,"ui-magnifier",this);$(el).addClass("ui-magnifier");o.distance=o.distance||150;o.magnification=o.magnification||2;o.baseline=o.baseline||0;o.verticalLine=o.verticalLine!=undefined?o.verticalLine:-0.5;this.pp=$(el).offset({border:false});$("> *",el).each(function(){var co=$(this).offset({border:false});if(self.options.overlap){var cp=$(this).position()}self.items.push([this,co,[$(this).width(),$(this).height()],(cp||null)]);if(o.opacity){$(this).css("opacity",o.opacity.min)}});if(o.overlap){for(var i=0;i<this.items.length;i++){$(this.items[i][0]).css({position:"absolute",top:this.items[i][3].top,left:this.items[i][3].left})}}this.moveEvent=function(e){if(!self.disabled){self.magnify.apply(self,[e])}};$(document).bind("mousemove",this.moveEvent);if(o.click){this.clickEvent=function(e){if(!self.disabled){o.click.apply(this,[e,{options:self.options,current:self.current[0],currentOffset:self.current[1]}])}};$(el).bind("click",this.clickEvent)}};$.extend($.ui.magnifier.prototype,{destroy:function(){$(this.element).removeClass("ui-magnifier").removeClass("ui-magnifier-disabled");$(document).unbind("mousemove",this.moveEvent);if(this.clickEvent){$(this.element).unbind("click",this.clickEvent)}},enable:function(){$(this.element).removeClass("ui-magnifier-disabled");this.disabled=false},disable:function(){$(this.element).addClass("ui-magnifier-disabled");this.reset();this.disabled=true},reset:function(e){var o=this.options;var c;var distance=1;for(var i=0;i<this.items.length;i++){c=this.items[i];$(c[0]).css({width:c[2][0],height:c[2][1],top:(c[3]?c[3].top:0),left:(c[3]?c[3].left:0)});if(o.opacity){$(c[0]).css("opacity",o.opacity.min)}if(o.zIndex){$(c[0]).css("z-index","")}}},magnify:function(e){var p=[e.pageX,e.pageY];var o=this.options;var c;this.current=this.items[0];var distance=1;var overlap=((p[0]>this.pp.left-o.distance&&p[0]<this.pp.left+this.element.offsetWidth+o.distance)&&(p[1]>this.pp.top-o.distance&&p[1]<this.pp.top+this.element.offsetHeight+o.distance));if(!overlap){return false}for(var i=0;i<this.items.length;i++){c=this.items[i];var olddistance=distance;if(!o.axis){distance=Math.sqrt(Math.pow(p[0]-((c[3]?this.pp.left:c[1].left)+parseInt(c[0].style.left))-(c[0].offsetWidth/2),2)+Math.pow(p[1]-((c[3]?this.pp.top:c[1].top)+parseInt(c[0].style.top))-(c[0].offsetHeight/2),2))}else{if(o.axis=="y"){distance=Math.abs(p[1]-((c[3]?this.pp.top:c[1].top)+parseInt(c[0].style.top))-(c[0].offsetHeight/2))}else{distance=Math.abs(p[0]-((c[3]?this.pp.left:c[1].left)+parseInt(c[0].style.left))-(c[0].offsetWidth/2))}}if(distance<o.distance){this.current=distance<olddistance?this.items[i]:this.current;if(!o.axis||o.axis!="y"){$(c[0]).css({width:c[2][0]+(c[2][0]*(o.magnification-1))-(((distance/o.distance)*c[2][0])*(o.magnification-1)),left:(c[3]?(c[3].left+o.verticalLine*((c[2][1]*(o.magnification-1))-(((distance/o.distance)*c[2][1])*(o.magnification-1)))):0)})}if(!o.axis||o.axis!="x"){$(c[0]).css({height:c[2][1]+(c[2][1]*(o.magnification-1))-(((distance/o.distance)*c[2][1])*(o.magnification-1)),top:(c[3]?c[3].top:0)+(o.baseline-0.5)*((c[2][0]*(o.magnification-1))-(((distance/o.distance)*c[2][0])*(o.magnification-1)))})}if(o.opacity){$(c[0]).css("opacity",o.opacity.max-(distance/o.distance)<o.opacity.min?o.opacity.min:o.opacity.max-(distance/o.distance))}}else{$(c[0]).css({width:c[2][0],height:c[2][1],top:(c[3]?c[3].top:0),left:(c[3]?c[3].left:0)});if(o.opacity){$(c[0]).css("opacity",o.opacity.min)}}if(o.zIndex){$(c[0]).css("z-index","")}}if(this.options.zIndex){$(this.current[0]).css("z-index",this.options.zIndex)}}})})($);(function(A){A.ui=A.ui||{};A.extend(A.expr[":"],{shadowed:"(' '+a.className+' ').indexOf(' ui-shadowed ')"});A.fn.shadowEnable=function(){if(A(this[0]).next().is(".ui-shadow")){A(this[0]).next().show()}};A.fn.shadowDisable=function(){if(A(this[0]).next().is(".ui-shadow")){A(this[0]).next().hide()}};A.fn.shadow=function(B){B=B||{};B.offset=B.offset?B.offset:0;B.opacity=B.opacity?B.opacity:0.2;return this.each(function(){var H=A(this);var I=A("<div class='ui-shadow'></div>");H.after(I);var F=H.outerWidth();var E=H.outerHeight();var D=H.position();A('<div class="ui-shadow-color ui-shadow-layer-1"></div>').css({opacity:B.opacity-0.05,left:5+B.offset,top:5+B.offset,width:F+1,height:E+1}).appendTo(I);A('<div class="ui-shadow-color ui-shadow-layer-2"></div>').css({opacity:B.opacity-0.1,left:7+B.offset,top:7+B.offset,width:F,height:E-3}).appendTo(I);A('<div class="ui-shadow-color ui-shadow-layer-3"></div>').css({opacity:B.opacity-0.1,left:7+B.offset,top:7+B.offset,width:F-3,height:E}).appendTo(I);A('<div class="ui-shadow-color ui-shadow-layer-4"></div>').css({opacity:B.opacity,left:6+B.offset,top:6+B.offset,width:F-1,height:E-1}).appendTo(I);if(B.color){A("div.ui-shadow-color",I).css("background-color",B.color)}if(!H.css("zIndex")||H.css("zIndex")=="auto"){var C=0;H.css("position",(H.css("position")=="static"?"relative":H.css("position"))).css("z-index","1")}else{var C=parseInt(H.css("zIndex"));H.css("zIndex",C+1)}I.css({position:"absolute",zIndex:C,left:D.left,top:D.top,width:F,height:E,marginLeft:H.css("marginLeft"),marginRight:H.css("marginRight"),marginBottom:H.css("marginBottom"),marginTop:H.css("marginTop")});function G(L,K){var J=A(L);A(K).css(J.position());A(K).children().css({height:J.outerHeight()+"px",width:J.outerWidth()+"px"})}if(A.browser.msie){I[0].style.setExpression("left","parseInt(jQuery(this.previousSibling).css('left'))+'px' || jQuery(this.previousSibling).position().left");I[0].style.setExpression("top","parseInt(jQuery(this.previousSibling).css('top'))+'px' || jQuery(this.previousSibling).position().top")}else{this.addEventListener("DOMAttrModified",function(){G(this,I)},false)}})}})($);(function($){window.webforms=1;if(window["webforms"]){$(document).ready(function(){$("input").each(function(){if(this.getAttribute("type")=="range"){var cur=$(this);var slider=$("<div class='ui-slider'></div>").css({width:cur.innerWidth()+"px",height:cur.innerHeight()+"px"}).insertAfter(cur);var handle=$("<div class='ui-slider-handle'></div>").appendTo(slider);slider.css({"position":cur.css("position")=="absolute"?"absolute":"relative","left":cur.css("left"),"right":cur.css("right"),"zIndex":cur.css("zIndex"),"float":cur.css("float"),"clear":cur.css("clear")});cur.css({position:"absolute",opacity:0,top:"-1000px",left:"-1000px"});slider.slider({maxValue:cur.attr("max"),minValue:cur.attr("min"),startValue:this.getAttribute("value"),stepping:cur.attr("step"),change:function(e,ui){cur[0].value=ui.value;cur[0].setAttribute("value",ui.value)}});slider=slider.sliderInstance();cur.bind("keydown",function(e){var o=slider.interaction.options;switch(e.keyCode){case 37:slider.moveTo(slider.interaction.curValue+o.minValue-(o.stepping||1));break;case 39:slider.moveTo(slider.interaction.curValue+o.minValue+(o.stepping||1));break}if(e.keyCode!=9){return false}})}})})}$.extend($.expr[":"],{slider:"(' '+a.className+' ').indexOf(' ui-slider ')"});$.fn.slider=function(o){return this.each(function(){new $.ui.slider(this,o)})};var methods="destroy,enable,disable,moveTo".split(",");for(var i=0;i<methods.length;i++){var cur=methods[i],f;eval('f = function() { var a = arguments; return this.each(function() { if(jQuery(this).is(".ui-slider")) jQuery.data(this, "ui-slider")["'+cur+'"](a); }); }');$.fn["slider"+cur.substr(0,1).toUpperCase()+cur.substr(1)]=f}$.fn.sliderInstance=function(){if($(this[0]).is(".ui-slider")){return $.data(this[0],"ui-slider")}return false};$.ui.slider=function(el,o){var options={};o=o||{};$.extend(options,o);$.extend(options,{axis:o.axis||(el.offsetWidth<el.offsetHeight?"vertical":"horizontal"),maxValue:parseInt(o.maxValue)||100,minValue:parseInt(o.minValue)||0,startValue:parseInt(o.startValue)||0,_start:function(h,p,c,t,e){self.start.apply(t,[self,e])},_beforeStop:function(h,p,c,t,e){self.stop.apply(t,[self,e])},_drag:function(h,p,c,t,e){self.drag.apply(t,[self,e])},startCondition:function(){return !self.disabled}});var self=this;var o=options;$.data(el,"ui-slider",this);o.stepping=parseInt(o.stepping)||(o.steps?o.maxValue/o.steps:0);o.realValue=(o.maxValue-o.minValue);this.handle=options.handle?$(options.handle,el):$(".ui-slider-handle",el);if(this.handle.length==1){this.interaction=new $.ui.mouseInteraction(this.handle[0],options);this.multipleHandles=false}else{this.interactions=[];this.handle.each(function(){self.interactions.push(new $.ui.mouseInteraction(this,options))});this.multipleHandles=true}this.element=el;$(this.element).addClass("ui-slider");if(o.axis=="horizontal"){this.parentSize=$(this.element).outerWidth()-this.handle.outerWidth();this.prop="left"}if(o.axis=="vertical"){this.parentSize=$(this.element).outerHeight()-this.handle.outerHeight();this.prop="top"}if(!this.multipleHandles){$(el).bind("click",function(e){self.click.apply(self,[e])});if(!isNaN(o.startValue)){this.moveTo(o.startValue,options.realValue,null,false)}}};$.extend($.ui.slider.prototype,{currentTarget:null,lastTarget:null,destroy:function(){$(this.element).removeClass("ui-slider").removeClass("ui-slider-disabled");this.interaction.destroy()},enable:function(){$(this.element).removeClass("ui-slider-disabled");this.disabled=false},disable:function(){$(this.element).addClass("ui-slider-disabled");this.disabled=true},nonvalidRange:function(self){for(var i=0;i<this.interactions.length;i++){if(self==this.interactions[i]){if(this.interactions[i-1]){if(this.interactions[i-1].curValue>this.interactions[i].curValue){return this.interactions[i-1].curValue}}if(this.interactions[i+1]){if(this.interactions[i+1].curValue<this.interactions[i].curValue){return this.interactions[i+1].curValue}}}}return false},prepareCallbackObj:function(self,m){var cur=this;var func=function(){var retVal=[];for(var i=0;i<cur.interactions.length;i++){retVal.push((cur.interactions[i].curValue||0)+self.options.minValue)}return retVal};return{handle:self.helper,pixel:m,value:self.curValue+self.options.minValue,values:this.multipleHandles?func():self.curValue+self.options.minValue,slider:self}},click:function(e){var o=this.interaction.options;var pointer=[e.pageX,e.pageY];var offset=$(this.interaction.element).offsetParent().offset({border:false});if(this.interaction.element==e.target||this.disabled){return }this.interaction.pickValue=this.interaction.curValue;this.drag.apply(this.interaction,[this,e,[pointer[0]-offset.left-this.handle[0].offsetWidth/2,pointer[1]-offset.top-this.handle[0].offsetHeight/2]]);if(this.interaction.pickValue!=this.interaction.curValue){$(this.element).triggerHandler("slidechange",[e,this.prepareCallbackObj(this.interaction)],o.change)}},start:function(that,e){var o=this.options;$(that.element).triggerHandler("slidestart",[e,that.prepareCallbackObj(this)],o.start);this.pickValue=this.curValue;return false},stop:function(that,e){var o=this.options;$(that.element).triggerHandler("slidestop",[e,that.prepareCallbackObj(this)],o.stop);if(this.pickValue!=this.curValue){$(that.element).triggerHandler("slidechange",[e,that.prepareCallbackObj(this)],o.change)}return false},drag:function(that,e,pos){var o=this.options;this.pos=pos||[this.pos[0]-this.element.offsetWidth/2,this.pos[1]-this.element.offsetHeight/2];if(o.axis=="horizontal"){var m=this.pos[0]}if(o.axis=="vertical"){var m=this.pos[1]}var p=that.parentSize;var prop=that.prop;if(m<0){m=0}if(m>p){m=p}this.curValue=(Math.round((m/p)*o.realValue));if(o.stepping){this.curValue=Math.round(this.curValue/o.stepping)*o.stepping;m=((this.curValue)/o.realValue)*p}if(that.interactions){nonvalidRange=that.nonvalidRange(this);if(nonvalidRange){this.curValue=nonvalidRange;m=((this.curValue)/o.realValue)*p}}$(this.element).css(prop,m+"px");$(that.element).triggerHandler("slide",[e,that.prepareCallbackObj(this,m)],o.slide);return false},moveTo:function(value,scale,changeslide,p){if(this.multipleHandles){return false}var o=this.interaction.options;var offset=$(this.interaction.element).offsetParent().offset({border:false});this.interaction.pickValue=this.interaction.curValue;value=value-o.minValue;var modifier=scale||o.realValue;var p=this.parentSize;var prop=this.prop;m=Math.round(((value)/modifier)*p);if(m<0){m=0}if(m>p){m=p}this.interaction.curValue=(Math.round((m/p)*o.realValue));if(o.stepping){this.interaction.curValue=Math.round(this.interaction.curValue/o.stepping)*o.stepping;m=((this.interaction.curValue)/o.realValue)*p}$(this.interaction.element).css(prop,m+"px");if(!changeslide&&this.interaction.pickValue!=this.interaction.curValue&&!p){$(this.element).triggerHandler("slidechange",[e,this.prepareCallbackObj(this.interaction)],o.change)}if(changeslide){$(this.element).triggerHandler("slide",[e,this.prepareCallbackObj(this.interaction)],o.slide)}}})})($);if(window.Node&&Node.prototype&&!Node.prototype.contains){Node.prototype.contains=function(A){return !!(this.compareDocumentPosition(A)&16)}}(function($){$.extend($.expr[":"],{sortable:"(' '+a.className+' ').indexOf(' ui-sortable ')"});$.fn.sortable=function(o){return this.each(function(){new $.ui.sortable(this,o)})};var methods="destroy,enable,disable,refresh".split(",");for(var i=0;i<methods.length;i++){var cur=methods[i],f;eval('f = function() { var a = arguments; return this.each(function() { if(jQuery(this).is(".ui-sortable")) jQuery.data(this, "ui-sortable")["'+cur+'"](a); }); }');$.fn["sortable"+cur.substr(0,1).toUpperCase()+cur.substr(1)]=f}$.fn.sortableInstance=function(){if($(this[0]).is(".ui-sortable")){return $.data(this[0],"ui-sortable")}return false};$.ui.sortable=function(el,o){this.element=el;this.set=[];var options={};var self=this;$.data(this.element,"ui-sortable",this);$(el).addClass("ui-sortable");$.extend(options,o);$.extend(options,{items:options.items||"> li",smooth:options.smooth!=undefined?options.smooth:true,helper:"clone",containment:options.containment?(options.containment=="sortable"?el:options.containment):null,zIndex:options.zIndex||1000,_start:function(h,p,c,t,e){self.start.apply(t,[self,e])},_beforeStop:function(h,p,c,t,e){self.stop.apply(t,[self,e])},_drag:function(h,p,c,t,e){self.drag.apply(t,[self,e])},startCondition:function(){return !self.disabled}});var items=$(options.items,el);options.floating=/left|right/.test(items.css("float"));if($(el).css("position")=="static"){$(el).css("position","relative")}options.offset=$(el).offset({border:false});items.each(function(){new $.ui.mouseInteraction(this,options)});items.each(function(){self.set.push([this,null])});this.options=options};$.extend($.ui.sortable.prototype,{plugins:{},currentTarget:null,lastTarget:null,prepareCallbackObj:function(self,that){return{helper:self.helper,position:{left:self.pos[0],top:self.pos[1]},offset:self.options.cursorAt,draggable:self,current:that,options:self.options}},refresh:function(){var self=this;var items=$(this.options.items,this.element);var unique=[];items.each(function(){old=false;for(var i=0;i<self.set.length;i++){if(self.set[i][0]==this){old=true}}if(!old){unique.push(this)}});for(var i=0;i<unique.length;i++){new $.ui.mouseInteraction(unique[i],self.options)}this.set=[];items.each(function(){self.set.push([this,null])})},destroy:function(){$(this.element).removeClass("ui-sortable").removeClass("ui-sortable-disabled");$(this.options.items,this.element).mouseInteractionDestroy()},enable:function(){$(this.element).removeClass("ui-sortable-disabled");this.disabled=false},disable:function(){$(this.element).addClass("ui-sortable-disabled");this.disabled=true},start:function(that,e){var o=this.options;if(o.hoverClass){that.helper=$('<div class="'+o.hoverClass+'"></div>').appendTo("body").css({height:this.element.offsetHeight+"px",width:this.element.offsetWidth+"px",position:"absolute"})}if(o.zIndex){if($(this.helper).css("zIndex")){o.ozIndex=$(this.helper).css("zIndex")}$(this.helper).css("zIndex",o.zIndex)}that.firstSibling=$(this.element).prev()[0];$(this.element).triggerHandler("sortstart",[e,that.prepareCallbackObj(this)],o.start);$(this.element).css("visibility","hidden");return false},stop:function(that,e){var o=this.options;var self=this;if(o.smooth){var os=$(this.element).offset();o.beQuietAtEnd=true;$(this.helper).animate({left:os.left-o.po.left,top:os.top-o.po.top},500,stopIt)}else{stopIt()}function stopIt(){$(self.element).css("visibility","visible");if(that.helper){that.helper.remove()}if(self.helper!=self.element){$(self.helper).remove()}if(o.ozIndex){$(self.helper).css("zIndex",o.ozIndex)}if($(self.element).prev()[0]!=that.firstSibling){}}return false},drag:function(that,e){var o=this.options;this.pos=[this.pos[0]-(o.cursorAt.left?o.cursorAt.left:0),this.pos[1]-(o.cursorAt.top?o.cursorAt.top:0)];var nv=$(this.element).triggerHandler("sort",[e,that.prepareCallbackObj(this)],o.sort);var nl=(nv&&nv.left)?nv.left:this.pos[0];var nt=(nv&&nv.top)?nv.top:this.pos[1];var m=that.set;var p=this.pos[1];for(var i=0;i<m.length;i++){var ci=$(m[i][0]);var cio=m[i][0];if(this.element.contains(cio)){continue}var cO=ci.offset();cO={top:cO.top,left:cO.left};var mb=function(e){if(true||o.lba!=cio){ci.before(e);o.lba=cio}};var ma=function(e){if(true||o.laa!=cio){ci.after(e);o.laa=cio}};if(o.floating){var overlap=((cO.left-(this.pos[0]+(this.options.po?this.options.po.left:0)))/this.helper.offsetWidth);if(!(cO.top<this.pos[1]+(this.options.po?this.options.po.top:0)+cio.offsetHeight/2&&cO.top+cio.offsetHeight>this.pos[1]+(this.options.po?this.options.po.top:0)+cio.offsetHeight/2)){continue}}else{var overlap=((cO.top-(this.pos[1]+(this.options.po?this.options.po.top:0)))/this.helper.offsetHeight);if(!(cO.left<this.pos[0]+(this.options.po?this.options.po.left:0)+cio.offsetWidth/2&&cO.left+cio.offsetWidth>this.pos[0]+(this.options.po?this.options.po.left:0)+cio.offsetWidth/2)){continue}}if(overlap>=0&&overlap<=0.5){ci.prev().length?ma(this.element):mb(this.element)}if(overlap<0&&overlap>-0.5){ci.next()[0]==this.element?mb(this.element):ma(this.element)}}if($(this.element).prev()[0]!=that.lastSibling){$(this.element).triggerHandler("sortchange",[e,that.prepareCallbackObj(this,that)],this.options.change);that.lastSibling=$(this.element).prev()[0]}if(that.helper){var to=$(this.element).offset();that.helper.css({top:to.top+"px",left:to.left+"px"})}$(this.helper).css("left",nl+"px").css("top",nt+"px");return false}})})($);(function($){$.extend({tablesorter:new function(){var parsers=[],widgets=[];this.defaults={cssHeader:"header",cssAsc:"headerSortUp",cssDesc:"headerSortDown",sortInitialOrder:"asc",sortMultiSortKey:"shiftKey",sortForce:null,textExtraction:"simple",parsers:{},widgets:[],widgetZebra:{css:["even","odd"]},headers:{},widthFixed:false,cancelSelection:true,sortList:[],headerList:[],dateFormat:"us",debug:false};function benchmark(label,stamp){log(label+","+(new Date().getTime()-stamp.getTime())+"ms")}function log(s){if(typeof console!="undefined"&&typeof console.debug!="undefined"){console.log(s)}else{alert(s)}}function buildParserCache(table,$headers){if(table.config.debug){var parsersDebug=""}var list=[],cells=table.tBodies[0].rows[0].cells,l=cells.length;for(var i=0;i<l;i++){var p=false;if($.meta&&($($headers[i]).data()&&$($headers[i]).data().sorter)){p=getParserById($($headers[i]).data().sorter)}else{if((table.config.headers[i]&&table.config.headers[i].sorter)){p=getParserById(table.config.headers[i].sorter)}}if(!p){p=detectParserForColumn(table.config,cells[i])}if(table.config.debug){parsersDebug+="column:"+i+" parser:"+p.id+"\n"}list.push(p)}if(table.config.debug){log(parsersDebug)}return list}function detectParserForColumn(config,node){var l=parsers.length;for(var i=1;i<l;i++){if(parsers[i].is($.trim(getElementText(config,node)))){return parsers[i]}}return parsers[0]}function getParserById(name){var l=parsers.length;for(var i=0;i<l;i++){if(parsers[i].id.toLowerCase()==name.toLowerCase()){return parsers[i]}}return false}function buildCache(table){if(table.config.debug){var cacheTime=new Date()}var totalRows=(table.tBodies[0]&&table.tBodies[0].rows.length)||0,totalCells=table.tBodies[0].rows[0].cells.length,parsers=table.config.parsers,cache={row:[],normalized:[]};for(var i=0;i<totalRows;++i){var c=table.tBodies[0].rows[i],cols=[];cache.row.push($(c));for(var j=0;j<totalCells;++j){cols.push(parsers[j].format(getElementText(table.config,c.cells[j]),table,c.cells[j]))}cols.push(i);cache.normalized.push(cols);cols=null}if(table.config.debug){benchmark("Building cache for "+totalRows+" rows:",cacheTime)}return cache}function getElementText(config,node){if(!node){return""}var t="";if(typeof (config.textExtraction)=="function"){t=config.textExtraction(node)}else{if(config.textExtraction=="complex"){t=$(node).text()}else{if(node.childNodes[0]&&node.childNodes[0].hasChildNodes()){t=node.childNodes[0].innerHTML}else{t=node.innerHTML}}}return t}function appendToTable(table,cache){if(table.config.debug){var appendTime=new Date()}var c=cache,r=c.row,n=c.normalized,totalRows=n.length,checkCell=(n[0].length-1),tableBody=$("tbody:first",table).empty();rows=[];for(var i=0;i<totalRows;i++){rows.push(r[n[i][checkCell]]);if(table.config.appender==null){tableBody.append(r[n[i][checkCell]])}}if(table.config.appender!=null){table.config.appender(table,rows)}rows=null;applyWidget(table);if(table.config.debug){benchmark("Rebuilt table:",appendTime)}}function buildHeaders(table){if(table.config.debug){var time=new Date()}var meta=($.meta)?true:false,tableHeadersRows=[];for(var i=0;i<table.tHead.rows.length;i++){tableHeadersRows[i]=0}$tableHeaders=$(checkCellColSpan(table,tableHeadersRows,0,table.tHead.rows[0].cells.length));$tableHeaders.each(function(index){this.count=0;this.column=index;this.order=formatSortingOrder(table.config.sortInitialOrder);if(checkHeaderMetadata(this)||checkHeaderOptions(table,index)){this.sortDisabled=true}if(!this.sortDisabled){$(this).addClass(table.config.cssHeader)}table.config.headerList[index]=this});if(table.config.debug){benchmark("Built headers:",time);log($tableHeaders)}return $tableHeaders}function checkCellColSpan(table,headerArr,row){var arr=[],r=table.tHead.rows,c=r[row].cells;for(var i=headerArr[row];i<c.length;i++){var cell=c[i];if(cell.colSpan>1){arr=arr.concat(checkCellColSpan(table,headerArr,row+cell.rowSpan))}else{if(table.tHead.length==1||(cell.rowSpan>1||!r[row+1])){arr.push(cell)}headerArr[row]=(i+row)}}return arr}function checkHeaderMetadata(cell){if(($.meta)&&($(cell).data().sorter===false)){return true}return false}function checkHeaderOptions(table,i){if((table.config.headers[i])&&(table.config.headers[i].sorter===false)){return true}return false}function applyWidget(table){var c=table.config.widgets;var l=c.length;for(var i=0;i<l;i++){getWidgetById(c[i]).format(table)}}function getWidgetById(name){var l=widgets.length;for(var i=0;i<l;i++){if(widgets[i].id.toLowerCase()==name.toLowerCase()){return widgets[i]}}}function formatSortingOrder(v){if(typeof (v)!="Number"){i=(v.toLowerCase()=="desc")?1:0}else{i=(v==(0||1))?v:0}return i}function isValueInArray(v,a){var l=a.length;for(var i=0;i<l;i++){if(a[i][0]==v){return true}}return false}function setHeadersCss(table,$headers,list,css){$headers.removeClass(css[0]).removeClass(css[1]);var h=[];$headers.each(function(offset){if(!this.sortDisabled){h[this.column]=$(this)}});var l=list.length;for(var i=0;i<l;i++){h[list[i][0]].addClass(css[list[i][1]])}}function fixColumnWidth(table,$headers){var c=table.config;if(c.widthFixed){var colgroup=$("<colgroup>");$("tbody:first tr:first td",table).each(function(){colgroup.append($("<col>").css("width",$(this).width()))});$(table).prepend(colgroup)}}function updateHeaderSortCount(table,sortList){var c=table.config,l=sortList.length;for(var i=0;i<l;i++){var s=sortList[i],o=c.headerList[s[0]];o.count=s[1];o.count++}}function multisort(table,sortList,cache){if(table.config.debug){var sortTime=new Date()}var dynamicExp="var sortWrapper = function(a,b) {",l=sortList.length;for(var i=0;i<l;i++){var c=sortList[i][0];var order=sortList[i][1];var s=(getCachedSortType(table.config.parsers,c)=="text")?((order==0)?"sortText":"sortTextDesc"):((order==0)?"sortNumeric":"sortNumericDesc");var e="e"+i;dynamicExp+="var "+e+" = "+s+"(a["+c+"],b["+c+"]); ";dynamicExp+="if("+e+") { return "+e+"; } ";dynamicExp+="else { "}for(var i=0;i<l;i++){dynamicExp+="}; "}dynamicExp+="return 0; ";dynamicExp+="}; ";eval(dynamicExp);cache.normalized.sort(sortWrapper);if(table.config.debug){benchmark("Sorting on "+sortList.toString()+" and dir "+order+" time:",sortTime)}return cache}function sortText(a,b){return((a<b)?-1:((a>b)?1:0))}function sortTextDesc(a,b){return((b<a)?-1:((b>a)?1:0))}function sortNumeric(a,b){return a-b}function sortNumericDesc(a,b){return b-a}function getCachedSortType(parsers,i){return parsers[i].type}this.construct=function(settings){return this.each(function(){var $this,$document,$headers,cache,config,shiftDown=0,sortOrder;this.config={};config=$.extend(this.config,$.tablesorter.defaults,settings);if(!this.tHead||!this.tBodies){return true}$this=$(this);$headers=buildHeaders(this);this.config.parsers=buildParserCache(this,$headers);cache=buildCache(this);var sortCSS=[config.cssDesc,config.cssAsc];fixColumnWidth(this);$headers.click(function(e){if(!this.sortDisabled){var $cell=$(this);var i=this.column;this.order=this.count++%2;if(!e[config.sortMultiSortKey]){config.sortList=[];if(config.sortForce!=null){var a=config.sortForce;for(var j=0;j<a.length;j++){config.sortList.push(a[j])}}config.sortList.push([i,this.order])}else{if(isValueInArray(i,config.sortList)){for(var j=0;j<config.sortList.length;j++){var s=config.sortList[j],o=config.headerList[s[0]];if(s[0]==i){o.count=s[1];o.count++;s[1]=o.count%2}}}else{config.sortList.push([i,this.order])}}setHeadersCss($this[0],$headers,config.sortList,sortCSS);appendToTable($this[0],multisort($this[0],config.sortList,cache));return false}}).mousedown(function(){if(config.cancelSelection){this.onselectstart=function(){return false};return false}});$this.bind("update",function(){cache=buildCache(this)}).bind("sorton",function(e,list){var sortList=config.sortList=list;updateHeaderSortCount(this,sortList);setHeadersCss(this,$headers,sortList,sortCSS);appendToTable(this,multisort(this,sortList,cache))}).bind("appendCache",function(){appendToTable(this,cache)}).bind("applyWidgetId",function(e,id){getWidgetById(id).format(this)});if($.meta&&($(this).data()&&$(this).data().sortlist)){config.sortList=$(this).data().sortlist}if(config.sortList.length>0){$this.trigger("sorton",[config.sortList])}applyWidget(this)})};this.addParser=function(parser){var l=parsers.length,a=true;for(var i=0;i<l;i++){if(parsers[i].id.toLowerCase()==parser.id.toLowerCase()){a=false}}if(a){parsers.push(parser)}};this.addWidget=function(widget){widgets.push(widget)};this.formatFloat=function(s){var i=parseFloat(s);return(isNaN(i))?0:i};this.formatInt=function(s){var i=parseInt(s);return(isNaN(i))?0:i}}});$.fn.extend({tablesorter:$.tablesorter.construct});$.tablesorter.addParser({id:"text",is:function(s){return true},format:function(s){return $.trim(s.toLowerCase())},type:"text"});$.tablesorter.addParser({id:"integer",is:function(s){return s.match(new RegExp(/^\d+$/))},format:function(s){return $.tablesorter.formatInt(s)},type:"numeric"});$.tablesorter.addParser({id:"currency",is:function(s){return/^[£$€?.]/.test(s)},format:function(s){return $.tablesorter.formatFloat(s.replace(new RegExp(/[^0-9.]/g),""))},type:"numeric"});$.tablesorter.addParser({id:"integer",is:function(s){return/^\d+$/.test(s)},format:function(s){return $.tablesorter.formatFloat(s)},type:"numeric"});$.tablesorter.addParser({id:"floating",is:function(s){return s.match(new RegExp(/^(\+|-)?[0-9]+\.[0-9]+((E|e)(\+|-)?[0-9]+)?$/))},format:function(s){return $.tablesorter.formatFloat(s.replace(new RegExp(/,/),""))},type:"numeric"});$.tablesorter.addParser({id:"ipAddress",is:function(s){return/^\d{2,3}[\.]\d{2,3}[\.]\d{2,3}[\.]\d{2,3}$/.test(s)},format:function(s){var a=s.split(".");var r="";for(var i=0,item;item=a[i];i++){if(item.length==2){r+="0"+item}else{r+=item}}return $.tablesorter.formatFloat(s)},type:"numeric"});$.tablesorter.addParser({id:"url",is:function(s){return/^(https?|ftp|file):\/\/$/.test(s)},format:function(s){return jQuery.trim(s.replace(new RegExp(/(https?|ftp|file):\/\//),""))},type:"text"});$.tablesorter.addParser({id:"isoDate",is:function(s){return/^\d{4}[\/-]\d{1,2}[\/-]\d{1,2}$/.test(s)},format:function(s){return $.tablesorter.formatFloat((s!="")?new Date(s.replace(new RegExp(/-/g),"/")).getTime():"0")},type:"numeric"});$.tablesorter.addParser({id:"percent",is:function(s){return/^\d{1,3}%$/.test(s)},format:function(s){return $.tablesorter.formatFloat(s.replace(new RegExp(/%/g),""))},type:"numeric"});$.tablesorter.addParser({id:"usLongDate",is:function(s){return/^[A-Za-z]{3,10}\.? [0-9]{1,2}, ([0-9]{4}|\'?[0-9]{2}) (([0-2]?[0-9]:[0-5][0-9])|([0-1]?[0-9]:[0-5][0-9]\s(AM|PM)))$/.test(s)},format:function(s){return $.tablesorter.formatFloat(new Date(s).getTime())},type:"numeric"});$.tablesorter.addParser({id:"shortDate",is:function(s){return/\d{1,2}[\/-]\d{1,2}[\/-]\d{2,4}/.test(s)},format:function(s,table){var c=table.config;s=s.replace(new RegExp(/-/g),"/");if(c.dateFormat=="us"){s=s.replace(new RegExp(/(\d{1,2})[\/-](\d{1,2})[\/-](\d{4})/),"$3/$1/$2")}else{if(c.dateFormat=="uk"){s=s.replace(new RegExp(/(\d{1,2})[\/-](\d{1,2})[\/-](\d{4})/),"$3/$2/$1")}else{if(c.dateFormat=="dd/mm/yy"||c.dateFormat=="dd-mm-yy"){s=s.replace(new RegExp(/(\d{1,2})[\/-](\d{1,2})[\/-](\d{2})/),"$1/$2/$3")}}}return $.tablesorter.formatFloat(new Date(s).getTime())},type:"numeric"});$.tablesorter.addParser({id:"time",is:function(s){return/^(([0-2]?[0-9]:[0-5][0-9])|([0-1]?[0-9]:[0-5][0-9]\s(am|pm)))$/.test(s)},format:function(s){return $.tablesorter.formatFloat(new Date("2000/01/01 "+s).getTime())},type:"numeric"});$.tablesorter.addParser({id:"metadata",is:function(s){return false},format:function(s,table,cell){var c=table.config,p=(!c.parserMetadataName)?"sortValue":c.parserMetadataName;return $(cell).data()[p]},type:"numeric"});$.tablesorter.addWidget({id:"zebra",format:function(table){$("> tbody:first/tr:visible:even",table).removeClass(table.config.widgetZebra.css[1]).addClass(table.config.widgetZebra.css[0]);$("> tbody:first/tr:visible:odd",table).removeClass(table.config.widgetZebra.css[0]).addClass(table.config.widgetZebra.css[1])}})})(jQuery);(function(A){A.ui=A.ui||{};A.fn.tabs=function(C,B){if(C&&C.constructor==Object){B=C;C=null}B=B||{};C=C&&C.constructor==Number&&--C||0;return this.each(function(){new A.ui.tabs(this,A.extend(B,{initial:C}))})};A.each(["Add","Remove","Enable","Disable","Click","Load"],function(B,C){A.fn["tabs"+C]=function(){var D=arguments;return this.each(function(){var E=A.ui.tabs.getInstance(this);E[C.toLowerCase()].apply(E,D)})}});A.fn.tabsSelected=function(){var D=-1;if(this[0]){var B=A.ui.tabs.getInstance(this[0]),C=A("li",this);D=C.index(C.filter("."+B.options.selectedClass)[0])}return D>=0?++D:-1};A.ui.tabs=function(D,B){this.source=D;this.options=A.extend({initial:0,event:"click",disabled:[],unselected:false,unselect:B.unselected?true:false,spinner:"Loading&#8230;",cache:false,idPrefix:"tab-",fxSpeed:"normal",add:function(){},remove:function(){},enable:function(){},disable:function(){},click:function(){},hide:function(){},show:function(){},load:function(){},navClass:"ui-tabs-nav",selectedClass:"ui-tabs-selected",disabledClass:"ui-tabs-disabled",containerClass:"ui-tabs-container",hideClass:"ui-tabs-hide",loadingClass:"ui-tabs-loading"},B);this.tabify(true);var C="tabs"+A.ui.tabs.prototype.count++;A.ui.tabs.instances[C]=this;A.data(D,"tabsUUID",C)};A.ui.tabs.instances={};A.ui.tabs.getInstance=function(B){return A.ui.tabs.instances[A.data(B,"tabsUUID")]};A.extend(A.ui.tabs.prototype,{count:0,tabify:function(N){this.$tabs=A("a:first-child",this.source);this.$containers=A([]);var P=this,C=this.options;this.$tabs.each(function(R,Q){if(Q.hash&&Q.hash.replace("#","")){P.$containers=P.$containers.add(Q.hash)}else{A.data(Q,"href",Q.href);var S=Q.title&&Q.title.replace(/\s/g,"_")||C.idPrefix+(P.count+1)+"-"+(R+1);Q.href="#"+S;P.$containers=P.$containers.add(A("#"+S)[0]||A('<div id="'+S+'" class="'+C.containerClass+'"></div>').insertAfter(P.$containers[R-1]||P.source))}});if(N){this.$tabs.each(function(S,Q){if(location.hash){if(Q.hash==location.hash){C.initial=S;if(A.browser.msie||A.browser.opera){var R=A(location.hash),T=R.attr("id");R.attr("id","");setTimeout(function(){R.attr("id",T)},500)}scrollTo(0,0);return false}}else{if(A(Q).parents("li:eq(0)").is("li."+C.selectedClass)){C.initial=S;return false}}});A(this.source).is("."+C.navClass)||A(this.source).addClass(C.navClass);this.$containers.each(function(){var Q=A(this);Q.is("."+C.containerClass)||Q.addClass(C.containerClass)});var J=A("li",this.source);this.$containers.addClass(C.hideClass);J.removeClass(C.selectedClass);if(!C.unselected){this.$containers.slice(C.initial,C.initial+1).show();J.slice(C.initial,C.initial+1).addClass(C.selectedClass)}if(A.data(this.$tabs[C.initial],"href")){this.load(C.initial+1,A.data(this.$tabs[C.initial],"href"));if(C.cache){A.removeData(this.$tabs[C.initial],"href")}}for(var F=0,G;G=C.disabled[F];F++){this.disable(G)}}var B={},O=C.fxShowSpeed||C.fxSpeed,M={},E=C.fxHideSpeed||C.fxSpeed;if(C.fxSlide||C.fxFade){if(C.fxSlide){B["height"]="show";M["height"]="hide"}if(C.fxFade){B["opacity"]="show";M["opacity"]="hide"}}else{if(C.fxShow){B=C.fxShow}else{B["min-width"]=0;O=1}if(C.fxHide){M=C.fxHide}else{M["min-width"]=0;E=1}}var I={display:"",overflow:"",height:""};if(!A.browser.msie){I["opacity"]=""}function L(R,Q,S){Q.animate(M,E,function(){Q.addClass(C.hideClass).css(I);if(A.browser.msie){Q[0].style.filter=""}C.hide(R,Q[0],S&&S[0]||null);if(S){K(R,S,Q)}})}function K(R,S,Q){if(!(C.fxSlide||C.fxFade||C.fxShow)){S.css("display","block")}S.animate(B,O,function(){S.removeClass(C.hideClass).css(I);if(A.browser.msie){S[0].style.filter=""}C.show(R,S[0],Q&&Q[0]||null)})}function D(R,Q,S){A(R).parents("li:eq(0)").addClass(C.selectedClass).siblings().removeClass(C.selectedClass);L(R,Q,S)}function H(T){var U=A(this).parents("li:eq(0)"),Q=P.$containers.filter(":visible"),S=A(this.hash);if((U.is("."+C.selectedClass)&&!C.unselect)||U.is("."+C.disabledClass)||C.click(this,S[0],Q[0])===false){this.blur();return false}if(C.unselect){if(U.is("."+C.selectedClass)){U.removeClass(C.selectedClass);P.$containers.stop();L(this,Q);this.blur();return false}else{if(!Q.length){U.addClass(C.selectedClass);P.$containers.stop();K(this,S);this.blur();return false}}}P.$containers.stop();if(S.length){if(A.data(this,"href")){var R=this;P.load(P.$tabs.index(this)+1,A.data(this,"href"),function(){D(R,Q,S)});if(C.cache){A.removeData(this,"href")}}else{D(this,Q,S)}}else{throw"jQuery UI Tabs: Mismatching fragment identifier."}this.blur();return false}this.$tabs.unbind(C.event,H).bind(C.event,H)},add:function(C,F,B){if(C&&F){var E=this.options;B=B||this.$tabs.length;if(B>=this.$tabs.length){var G="insertAfter";B=this.$tabs.length}else{var G="insertBefore"}if(C.indexOf("#")==0){var D=A(C);(D.length&&D||A('<div id="'+C.replace("#","")+'" class="'+E.containerClass+" "+E.hideClass+'"></div>'))[G](this.$containers[B-1])}A('<li><a href="'+C+'"><span>'+F+"</span></a></li>")[G](this.$tabs.slice(B-1,B).parents("li:eq(0)"));this.tabify();E.add(this.$tabs[B-1],this.$containers[B-1])}else{throw"jQuery UI Tabs: Not enough arguments to add tab."}},remove:function(B){if(B&&B.constructor==Number){var C=this.$tabs.slice(B-1,B).parents("li:eq(0)").remove();var D=this.$containers.slice(B-1,B).remove();this.tabify();this.options.remove(C[0],D[0])}},enable:function(B){var D=this.$tabs.slice(B-1,B).parents("li:eq(0)"),C=this.options;D.removeClass(C.disabledClass);if(A.browser.safari){D.animate({opacity:1},1,function(){D.css({opacity:""})})}C.enable(this.$tabs[B-1],this.$containers[B-1])},disable:function(B){var D=this.$tabs.slice(B-1,B).parents("li:eq(0)"),C=this.options;if(A.browser.safari){D.animate({opacity:0},1,function(){D.css({opacity:""})})}D.addClass(this.options.disabledClass);C.disable(this.$tabs[B-1],this.$containers[B-1])},click:function(B){this.$tabs.slice(B-1,B).trigger("click")},load:function(B,E,I){var D=this,H=this.options,F=this.$tabs.slice(B-1,B).addClass(H.loadingClass),C=A("span",F),G=C.html();if(E&&E.constructor==Function){I=E}if(E){A.data(F[0],"href",E)}if(H.spinner){C.html("<em>"+H.spinner+"</em>")}setTimeout(function(){A(F[0].hash).load(E,function(){if(H.spinner){C.html(G)}F.removeClass(H.loadingClass);if(I&&I.constructor==Function){I()}H.load(D.$tabs[B-1],D.$containers[B-1])})},0)}})})(jQuery);window.$ui=jQuery.noConflict(true)