/**
 * SWFAddress 2.2: Deep linking for Flash and Ajax <http://www.asual.com/swfaddress/>
 *
 * SWFAddress is (c) 2006-2008 Rostislav Hristov and contributors
 * This software is released under the MIT License <http://www.opensource.org/licenses/mit-license.php>
 *
 */
if(typeof asual=="undefined"){asual={};}if(typeof asual.swfaddress=="undefined"){asual.swfaddress={};}if(typeof asual.util=="undefined"){asual.util={};}asual.util.Browser=new function(){var B=-1,D=navigator.userAgent,H=false,G=false,F=false,A=false,C=false,I=false;var E=function(K,J){return parseFloat(D.substr(D.indexOf(K)+J));};if(A=/Opera/.test(D)){B=parseFloat(navigator.appVersion);}if(H=/MSIE/.test(D)){B=E("MSIE",4);}if(I=/Chrome/.test(D)){B=E("Chrome",7);}if(G=/Camino/.test(D)){B=E("Camino",7);}if(F=(/AppleWebKit/.test(D)&&!I)){B=E("Safari",7);}if(C=(/Firefox/.test(D)&&!G)){B=E("Firefox",8);}this.toString=function(){return "[class Browser]";};this.getVersion=function(){return B;};this.isIE=function(){return H;};this.isSafari=function(){return F;};this.isOpera=function(){return A;};this.isCamino=function(){return G;};this.isFirefox=function(){return C;};this.isChrome=function(){return I;};};asual.util.Events=new function(){var C="DOMContentLoaded",G="onstop",I=window,F=document,B=[],A=asual.util,D=A.Browser;this.toString=function(){return "[class Events]";};this.addListener=function(L,J,K){B.push({o:L,t:J,l:K});if(!(J==C&&(D.isIE()||D.isSafari()))){if(L.addEventListener){L.addEventListener(J,K,false);}else{if(L.attachEvent){L.attachEvent("on"+J,K);}}}};this.removeListener=function(N,K,L){for(var J=0,M;M=B[J];J++){if(M.o==N&&M.t==K&&M.l==L){B.splice(J,1);break;}}if(!(K==C&&(D.isIE()||D.isSafari()))){if(N.removeEventListener){N.removeEventListener(K,L,false);}else{if(N.detachEvent){N.detachEvent("on"+K,L);}}}};var H=function(){for(var K=0,J;J=B[K];K++){if(J.t!=C){A.Events.removeListener(J.o,J.t,J.l);}}};var E=function(){if(F.readyState=="interactive"){function J(){F.detachEvent(G,J);H();};F.attachEvent(G,J);I.setTimeout(function(){F.detachEvent(G,J);},0);}};if(D.isIE()||D.isSafari()){(function(){try{if((D.isIE()&&F.body)||!/loaded|complete/.test(F.readyState)){F.documentElement.doScroll("left");}}catch(K){return setTimeout(arguments.callee,0);}for(var J=0,K;K=B[J];J++){if(K.t==C){K.l.call(null);}}})();}if(D.isIE()){I.attachEvent("onbeforeunload",E);}this.addListener(I,"unload",H);};asual.util.Functions=new function(){this.toString=function(){return "[class Functions]";};this.extend=function(C,A){function B(){};B.prototype=C.prototype;A.prototype=new B();A.prototype.constructor=A;A.superConstructor=C;A.superClass=C.prototype;return A;};this.bind=function(F,B,E){for(var C=2,D,A=[];D=arguments[C];C++){A.push(D);}return function(){return F.apply(B,A);};};};asual.swfaddress.WEBAddressEvent=function(D){var A=asual.swfaddress.WEBAddress;this.toString=function(){return "[object WEBAddressEvent]";};this.type=D;this.target=[A][0];this.value=A.getValue();this.path=A.getPath();this.pathNames=A.getPathNames();this.parameters={};var E=A.getParameterNames();for(var C=0,B=E.length;C<B;C++){this.parameters[E[C]]=A.getParameter(E[C]);}this.parametersNames=E;};asual.swfaddress.WEBAddressEvent.INIT="init";asual.swfaddress.WEBAddressEvent.CHANGE="change";asual.swfaddress.WEBAddress=new function(){var ID="",_2f="function",_30="undefined",_31=asual.swfaddress,_32=asual.util,_33=_32.Browser,_34=_32.Events,_35=_32.Functions,_36=_33.getVersion(),_37=false,_t=top,_d=_t.document,_h=_t.history,_l=_t.location,_si=setInterval,_st=setTimeout,_dc=decodeURIComponent,_ec=encodeURIComponent,_40,_41,_42,_43,_44=_d.title,_45=_h.length,_46=false,_47=false,_48=true,_49=true,_4a=[],_4b={},_4c={history:true,html:false,strict:true,tracker:"_trackDefault"};if(_33.isOpera()){_37=_36>=9.02;}if(_33.isIE()){_37=_36>=6;}if(_33.isSafari()){_37=_36>=312;}if(_33.isChrome()){_37=_36>=0.2;}if(_33.isCamino()){_37=_36>=1;}if(_33.isFirefox()){_37=_36>=1;}if((!_37&&_l.href.indexOf("#")!=-1)||(_33.isSafari()&&_36<412&&_l.href.indexOf("#")!=-1&&_l.search!="")){_d.open();_d.write("<html><head><meta http-equiv=\"refresh\" content=\"0;url="+_l.href.substr(0,_l.href.indexOf("#"))+"\" /></head></html>");_d.close();}var _4d=function(){var _4e=_l.href.indexOf("#");return _4e!=-1?_l.href.substr(_4e+1):"";};var _4f=_4d();var _50=function(_51,_52){if(_4c.strict){_51=_52?(_51.substr(0,1)!="/"?"/"+_51:_51):(_51==""?"/":_51);}return _51;};var _53=function(_54){return (_33.isIE()&&_l.protocol=="file:")?_4f.replace(/\?/,"%3F"):_54;};var _55=function(el){for(var i=0,l=el.childNodes.length,s;i<l;i++){if(el.childNodes[i].src){_42=String(el.childNodes[i].src);}if(s=_55(el.childNodes[i])){return s;}}};var _5a=function(){if(_33.isIE()&&_d.title!=_44&&_d.title.indexOf("#")!=-1){_d.title=_44;if(_4c.html&&_40&&_40.contentWindow&&_40.contentWindow.document){_40.contentWindow.document.title=_44;}}};var _5b=function(){if(!_46){var _5c=_4d();if(_33.isIE()){if(_4f!=_5c){if(_36<7){_l.reload();}else{this.setValue(_5c);}}}else{if(_33.isSafari()&&_36<523){if(_45!=_h.length){_45=_h.length;if(typeof _4a[_45-1]!=_30){_4f=_4a[_45-1];}_5d.call(this);}}else{if(_4f!=_5c){_4f=_5c;_5d.call(this);}}}_5a.call(this);}};var _5e=function(_5f){this.dispatchEvent(new _31.WEBAddressEvent(_5f));_5f=_5f.substr(0,1).toUpperCase()+_5f.substr(1);if(typeof this["on"+_5f]==_2f){this["on"+_5f]();}};var _60=function(){_5e.call(this,"init");};var _61=function(){_5e.call(this,"change");};var _5d=function(){_61.call(this);_st(_35.bind(_62,this),10);};var _63=function(_64){if(typeof urchinTracker==_2f){urchinTracker(_64);}if(typeof pageTracker!=_30&&typeof pageTracker._trackPageview==_2f){pageTracker._trackPageview(_64);}};eval("var _trackDefault = "+_63+";");var _62=function(){if(typeof _4c.tracker!=_30&&eval("typeof "+_4c.tracker+" != \""+_30+"\"")){var fn=eval(_4c.tracker);if(typeof fn==_2f){fn((_l.pathname+(/\/$/.test(_l.pathname)?"":"/")+this.getValue()).replace(/\/\//,"/").replace(/^\/$/,""));}}};var _66=function(){var doc=_40.contentWindow.document;doc.open();doc.write("<html><head><title>"+_d.title+"</title><script>var "+ID+" = \""+_ec(_4d())+"\";</script></head></html>");doc.close();};var _68=function(){var win=_40.contentWindow;var src=win.location.href;_4f=(_4c.html)?(src.indexOf("?")>-1?_dc(src.substr(src.indexOf("?")+1)):""):(typeof win[ID]!=_30?_dc(win[ID]):"");if(_4c.html){win.document.title=_44;}if(_4f!=_4d()){_5d.call(_31.WEBAddress);_l.hash=_53(_4f);}};var _6b=function(){if(!_47){_47=true;var _6c="id=\""+ID+"\" style=\"position:absolute;top:-9999px;\"";if(_33.isIE()&&_36<8){_d.body.appendChild(_d.createElement("div")).innerHTML="<iframe "+_6c+" src=\""+(_4c.html?_42.replace(/\.js(\?.*)?$/,".html")+"?"+_ec(_4d()):"javascript:false;")+"\" width=\"0\" height=\"0\"></iframe>";_40=_d.getElementById(ID);_st(function(){_34.addListener(_40,"load",_68);if(!_4c.html&&typeof _40.contentWindow[ID]==_30){_66();}},50);}else{if(_33.isSafari()){if(_36<412){_d.body.innerHTML+="<form "+_6c+" method=\"get\"></form>";_41=_d.getElementById(ID);}if(typeof _l[ID]==_30){_l[ID]={};}if(typeof _l[ID][_l.pathname]!=_30){_4a=_l[ID][_l.pathname].split(",");}}}_st(_35.bind(_60,this),1);_st(_35.bind(_61,this),2);_st(_35.bind(_62,this),10);if(_33.isIE()&&_36>=8){_d.body.onhashchange=_35.bind(_5b,this);_43=_si(_35.bind(_5a,this),50);}else{_43=_si(_35.bind(_5b,this),50);}}};var _6d=function(){clearInterval(_43);};this.onInit=null;this.onChange=null;this.toString=function(){return "[class WEBAddress]";};this.back=function(){_h.back();};this.forward=function(){_h.forward();};this.up=function(){var _6e=this.getPath();this.setValue(_6e.substr(0,_6e.lastIndexOf("/",_6e.length-2)+(_6e.substr(_6e.length-1)=="/"?1:0)));};this.go=function(_6f){_h.go(_6f);};this.addEventListener=function(_70,_71){if(typeof _4b[_70]==_30){_4b[_70]=[];}_4b[_70].push(_71);};this.removeEventListener=function(_72,_73){if(typeof _4b[_72]!=_30){for(var i=0,l;l=_4b[_72][i];i++){if(l==_73){break;}}_4b[_72].splice(i,1);}};this.dispatchEvent=function(_76){if(this.hasEventListener(_76.type)){_76.target=this;for(var i=0,l;l=_4b[_76.type][i];i++){l(_76);}return true;}return false;};this.hasEventListener=function(_79){return (typeof _4b[_79]!=_30&&_4b[_79].length>0);};this.getBaseURL=function(){var url=_l.href;if(url.indexOf("#")!=-1){url=url.substr(0,url.indexOf("#"));}if(url.substr(url.length-1)=="/"){url=url.substr(0,url.length-1);}return url;};this.getStrict=function(){return _4c.strict;};this.setStrict=function(_7b){_4c.strict=_7b;};this.getHistory=function(){return _4c.history;};this.setHistory=function(_7c){_4c.history=_7c;};this.getTracker=function(){return _4c.tracker;};this.setTracker=function(_7d){_4c.tracker=_7d;};this.getTitle=function(){return _d.title;};this.setTitle=function(_7e){if(!_37){return null;}if(typeof _7e==_30){return;}if(_7e=="null"){_7e="";}_44=_d.title=_7e;_st(function(){if((_49||_4c.html)&&_40&&_40.contentWindow&&_40.contentWindow.document){_40.contentWindow.document.title=_7e;_49=false;}if(!_48&&(_33.isCamino()||_33.isFirefox())){_l.replace(_l.href.indexOf("#")!=-1?_l.href:_l.href+"#");}_48=false;},50);};this.getStatus=function(){return _t.status;};this.setStatus=function(_7f){if(typeof _7f==_30){return;}if(!_33.isSafari()){_7f=_50((_7f!="null")?_7f:"",true);if(_7f=="/"){_7f="";}if(!(/http(s)?:\/\//.test(_7f))){var _80=_l.href.indexOf("#");_7f=(_80==-1?_l.href:_l.href.substr(0,_80))+"#"+_7f;}_t.status=_7f;}};this.resetStatus=function(){_t.status="";};this.getValue=function(){if(!_37){return null;}return _50(_4f,false);};this.setValue=function(_81){if(!_37){return null;}if(typeof _81==_30){return;}if(_81=="null"){_81="";}_81=_50(_81,true);if(_81=="/"){_81="";}if(_4f==_81){return;}_48=true;_4f=_81;_46=true;_5d.call(_31.WEBAddress);_4a[_h.length]=_4f;if(_33.isSafari()){if(_4c.history){_l[ID][_l.pathname]=_4a.toString();_45=_h.length+1;if(_36<412){if(_l.search==""){_41.action="#"+_4f;_41.submit();}}else{if(_36<523||_4f==""){var evt=_d.createEvent("MouseEvents");evt.initEvent("click",true,true);var _83=_d.createElement("a");_83.href="#"+_4f;_83.dispatchEvent(evt);}else{_l.hash="#"+_4f;}}}else{_l.replace("#"+_4f);}}else{if(_4f!=_4d()){if(_4c.history){_l.hash=(_33.isChrome()?"":"#")+_53(_4f);}else{_l.replace("#"+_4f);}}}if((_33.isIE()&&_36<8)&&_4c.history){if(_4c.html){var loc=_40.contentWindow.location;loc.assign(loc.pathname+"?"+_4d());}else{_st(_66,50);}}if(_33.isSafari()){_st(function(){_46=false;},1);}else{_46=false;}};this.getPath=function(){var _85=this.getValue();return (_85.indexOf("?")!=-1)?_85.split("?")[0]:_85;};this.getPathNames=function(){var _86=this.getPath();var _87=_86.split("/");if(_86.substr(0,1)=="/"||_86.length==0){_87.splice(0,1);}if(_86.substr(_86.length-1,1)=="/"){_87.splice(_87.length-1,1);}return _87;};this.getQueryString=function(){var _88=this.getValue();var _89=_88.indexOf("?");return (_89!=-1&&_89<_88.length)?_88.substr(_89+1):"";};this.getParameter=function(_8a){var _8b=this.getValue();var _8c=_8b.indexOf("?");if(_8c!=-1){_8b=_8b.substr(_8c+1);var _8d=_8b.split("&");var p,i=_8d.length;while(i--){p=_8d[i].split("=");if(p[0]==_8a){return p[1];}}}return "";};this.getParameterNames=function(){var _90=this.getValue();var _91=_90.indexOf("?");var _92=[];if(_91!=-1){_90=_90.substr(_91+1);if(_90!=""&&_90.indexOf("=")!=-1){var _93=_90.split("&");var i=0;while(i<_93.length){_92.push(_93[i].split("=")[0]);i++;}}}return _92;};if(_37){for(var i=1;i<_45;i++){_4a.push("");}_4a.push(_4d());if(_33.isIE()&&_l.hash!=_4d()){_l.hash="#"+_53(_4d());}_55(document);var _qi=_42.indexOf("?");if(_42&&_qi>-1){var _97,_98=_42.substr(_qi+1).split("&");for(var i=0,p;p=_98[i];i++){_97=p.split("=");if(/^(history|html|strict)$/.test(_97[0])){_4c[_97[0]]=(isNaN(_97[1])?eval(_97[1]):(parseFloat(_97[1])>0));}if(/^tracker$/.test(_97[0])){_4c[_97[0]]=_97[1];}}}if(/file:\/\//.test(_l.href)){_4c.html=false;}var _ei=_42.indexOf(".js"),l;if(_42&&_ei>-1){while(_ei--){l=_42.substr(_ei,1);if(/(\/|\\)/.test(l)){break;}ID=l+ID;}}_5a.call(this);if(window==_t){_34.addListener(document,"DOMContentLoaded",_35.bind(_6b,this));}_34.addListener(_t,"load",_35.bind(_6b,this));_34.addListener(_t,"unload",_35.bind(_6d,this));}else{_62();}};SWFAddressEvent=asual.swfaddress.SWFAddressEvent=function(A){SWFAddressEvent.superConstructor.apply(this,arguments);this.target=[SWFAddress][0];this.toString=function(){return "[object SWFAddressEvent]";};};asual.util.Functions.extend(asual.swfaddress.WEBAddressEvent,SWFAddressEvent);asual.swfaddress.SWFAddressEvent.INIT="init";asual.swfaddress.SWFAddressEvent.CHANGE="change";SWFAddress=asual.swfaddress.SWFAddress=new function(){var _9d="undefined",_t=top,_l=_t.location,_a0=this,_a1=[],_a2=[],_a3={},_a4=asual.util,_a5=asual.util.Functions,_a6=asual.swfaddress.WEBAddress;for(var p in _a6){this[p]=_a6[p];}var _a8=function(_a9){this.dispatchEvent(new SWFAddressEvent(_a9));_a9=_a9.substr(0,1).toUpperCase()+_a9.substr(1);if(typeof this["on"+_a9]=="function"){this["on"+_a9]();}};var _aa=function(e){if(_a2.length>0){var _ac=window.open(_a2[0],_a2[1],eval(_a2[2]));if(typeof _a2[3]!=_9d){eval(_a2[3]);}}_a2=[];};var _ad=function(){if(_a4.Browser.isSafari()){document.body.addEventListener("click",_aa);}_a8.call(this,"init");};var _ae=function(){_af();_a8.call(this,"change");};var _af=function(){for(var i=0,id,obj,_b3=SWFAddress.getValue(),_b4="setSWFAddressValue";id=_a1[i];i++){obj=document.getElementById(id);if(obj){if(obj.parentNode&&typeof obj.parentNode.so!=_9d){obj.parentNode.so.call(_b4,_b3);}else{if(!(obj&&typeof obj[_b4]!=_9d)){var _b5=obj.getElementsByTagName("object");var _b6=obj.getElementsByTagName("embed");obj=((_b5[0]&&typeof _b5[0][_b4]!=_9d)?_b5[0]:((_b6[0]&&typeof _b6[0][_b4]!=_9d)?_b6[0]:null));}if(obj){obj[_b4](_b3);}}}else{if(obj=document[id]){if(typeof obj[_b4]!=_9d){obj[_b4](_b3);}}}}};this.toString=function(){return "[class SWFAddress]";};this.addEventListener=function(_b7,_b8){if(typeof _a3[_b7]==_9d){_a3[_b7]=[];}_a3[_b7].push(_b8);};this.removeEventListener=function(_b9,_ba){if(typeof _a3[_b9]!=_9d){for(var i=0,l;l=_a3[_b9][i];i++){if(l==_ba){break;}}_a3[_b9].splice(i,1);}};this.dispatchEvent=function(_bd){if(typeof _a3[_bd.type]!=_9d&&_a3[_bd.type].length){_bd.target=this;for(var i=0,l;l=_a3[_bd.type][i];i++){l(_bd);}return true;}return false;};this.hasEventListener=function(_c0){return (typeof _a3[_c0]!=_9d&&_a3[_c0].length>0);};this.href=function(url,_c2){_c2=typeof _c2!=_9d?_c2:"_self";if(_c2=="_self"){self.location.href=url;}else{if(_c2=="_top"){_l.href=url;}else{if(_c2=="_blank"){window.open(url);}else{_t.frames[_c2].location.href=url;}}}};this.popup=function(url,_c4,_c5,_c6){try{var _c7=window.open(url,_c4,eval(_c5));if(typeof _c6!=_9d){eval(_c6);}}catch(ex){}_a2=arguments;};this.getIds=function(){return _a1;};this.getId=function(_c8){return _a1[0];};this.setId=function(id){_a1[0]=id;};this.addId=function(id){this.removeId(id);_a1.push(id);};this.removeId=function(id){for(var i=0;i<_a1.length;i++){if(id==_a1[i]){_a1.splice(i,1);break;}}};_a6.addEventListener("init",_a5.bind(_ad,this));_a6.addEventListener("change",_a5.bind(_ae,this));(function(){var _cd;if(typeof FlashObject!=_9d){SWFObject=FlashObject;}if(typeof SWFObject!=_9d&&SWFObject.prototype&&SWFObject.prototype.write){var _s1=SWFObject.prototype.write;SWFObject.prototype.write=function(){_cd=arguments;if(this.getAttribute("version").major<8){this.addVariable("$swfaddress",SWFAddress.getValue());((typeof _cd[0]=="string")?document.getElementById(_cd[0]):_cd[0]).so=this;}var _cf;if(_cf=_s1.apply(this,_cd)){_a0.addId(this.getAttribute("id"));}return _cf;};}if(typeof swfobject!=_9d){var _d0=swfobject.registerObject;swfobject.registerObject=function(){_cd=arguments;_d0.apply(this,_cd);_a0.addId(_cd[0]);};var _d1=swfobject.createSWF;swfobject.createSWF=function(){_cd=arguments;_d1.apply(this,_cd);_a0.addId(_cd[0].id);};var _d2=swfobject.embedSWF;swfobject.embedSWF=function(){_cd=arguments;_d2.apply(this,_cd);_a0.addId(_cd[8].id);};}if(typeof UFO!=_9d){var _u=UFO.create;UFO.create=function(){_cd=arguments;_u.apply(this,_cd);_a0.addId(_cd[0].id);};}if(typeof AC_FL_RunContent!=_9d){var _a=AC_FL_RunContent;AC_FL_RunContent=function(){_cd=arguments;_a.apply(this,_cd);for(var i=0,l=_cd.length;i<l;i++){if(_cd[i]=="id"){_a0.addId(_cd[i+1]);}}};}})();};
