BrowserHistoryUtils={addEvent:function(E,D,B,A){A=A||false;
if(E.addEventListener){E.addEventListener(D,B,A);
return true
}else{if(E.attachEvent){var C=E.attachEvent("on"+D,B);
return C
}else{E["on"+D]=B
}}}};
BrowserHistory=(function(){var b={ie:false,firefox:false,safari:false,opera:false,version:-1};
var C="";
var D=document.location.href;
var W=document.location.href;
var B=document.location.hash;
var H="history/historyFrame.html?";
var T=-1;
var e=[];
var V=L(W,W+"#"+B,B);
var Y=[];
var K=[];
var I=null;
var S=navigator.userAgent.toLowerCase();
if(S.indexOf("opera")!=-1){b.opera=true
}else{if(S.indexOf("msie")!=-1){b.ie=true;
b.version=parseFloat(S.substring(S.indexOf("msie")+4))
}else{if(S.indexOf("safari")!=-1){b.safari=true;
b.version=parseFloat(S.substring(S.indexOf("safari")+7))
}else{if(S.indexOf("gecko")!=-1){b.firefox=true
}}}}if(b.ie==true&&b.version==7){window._ie_firstload=false
}function N(){return document.getElementById("ie_historyFrame")
}function Q(){return document.getElementById("firefox_anchorDiv")
}function P(){return document.getElementById("safari_formDiv")
}function A(){return document.getElementById("safari_remember_field")
}function O(i){if(i&&document.getElementById(i)){var f=document.getElementById(i);
if(typeof f.SetVariable!="undefined"){return f
}else{var h=f.getElementsByTagName("object");
var g=f.getElementsByTagName("embed");
if(h.length>0&&typeof h[0].SetVariable!="undefined"){return h[0]
}else{if(g.length>0&&typeof g[0].SetVariable!="undefined"){return g[0]
}}}}else{var h=document.getElementsByTagName("object");
var g=document.getElementsByTagName("embed");
if(g.length>0&&typeof g[0].SetVariable!="undefined"){return g[0]
}else{if(h.length>0&&typeof h[0].SetVariable!="undefined"){return h[0]
}else{if(h.length>1&&typeof h[1].SetVariable!="undefined"){return h[1]
}}}}return undefined
}function U(){var g=[];
if(g.length==0){var f=document.getElementsByTagName("object");
g=f
}if(g.length==0||g[0].object==null){var f=document.getElementsByTagName("embed");
g=f
}return g
}function G(){var g=N().contentWindow.document;
var f=String(g.location.search);
if(f.length==1&&f.charAt(0)=="?"){f=""
}else{if(f.length>=2&&f.charAt(0)=="?"){f=f.substring(1)
}}return f
}function M(){var f=document.location.href.indexOf("#");
return(f>=0)?document.location.href.substr(f+1):""
}function F(f){if(f==""){f="#"
}document.location.hash=f
}function L(f,g,h){return{baseUrl:f,newUrl:g,flexAppUrl:h,title:null}
}function d(m,f,o){K=[];
if(b.ie){if(o==C&&document.location.href==W&&window._ie_firstload){D=W;
return 
}if((!o||o==C)&&window._ie_firstload){f=m+"#"+C;
o=C
}else{N().src=H+o
}F(o)
}else{if(Y.length==0&&V.flexAppUrl==o){V=L(m,f,o)
}else{if(Y.length>0&&Y[Y.length-1].flexAppUrl==o){Y[Y.length-1]=L(m,f,o)
}}if(b.safari){if(b.version<=419.3){var h=window.location.pathname.toString();
h=h.substring(h.lastIndexOf("/")+1);
P().innerHTML='<form name="historyForm" action="'+h+"#"+o+'" method="GET"></form>';
var n=window.location.search.substring(1);
var j=n.split("&");
for(var k=0;
k<j.length;
k++){var l=j[k].split("=");
var g=document.createElement("input");
g.type="hidden";
g.name=l[0];
g.value=l[1];
document.forms.historyForm.appendChild(g)
}document.forms.historyForm.submit()
}else{top.location.hash=o
}e[history.length]=o;
X()
}else{a(o);
F(o)
}}Y.push(L(m,f,o))
}function X(){if(b.safari){A().value=e.join(",")
}}function J(){var g=Y.pop();
if(!g){return 
}var f=Y[Y.length-1];
if(!f&&Y.length==0){f=V
}K.push(g)
}function Z(){var f=K.pop();
if(!f){return 
}Y.push(f)
}function E(){K=[]
}function R(){if(b.ie){if(D!=document.location.href&&D+"#"!=document.location.href){if(b.version<7){D=document.location.href;
document.location.reload()
}else{if(M()!=G()){var f=H+M();
N().src=f
}}}}if(b.safari){if(T>=0&&history.length!=T){T=history.length;
var m=e[T];
if(m==""){}if(typeof BrowserHistory_multiple!="undefined"&&BrowserHistory_multiple==true){var k=U();
for(var j=0;
j<k.length;
j++){k[j].browserURLChange(m)
}}else{O().browserURLChange(m)
}X()
}}if(b.firefox){if(D!=document.location.href){var h=Y.length;
var l={back:false,forward:false,set:false};
if((window.location.hash==B||window.location.href==W)&&(h==1)){l.back=true;
J()
}if(K.length>0){if(K[K.length-1].flexAppUrl==M()){l.forward=true;
Z()
}}if((h>=2)&&(Y[h-2])){if(Y[h-2].flexAppUrl==M()){l.back=true;
J()
}}if(!l.back&&!l.forward){var g={back:-1,forward:-1};
for(var j=0;
j<Y.length;
j++){if(Y[j].flexAppUrl==M()&&j!=(h-2)){arbitraryUrl=true;
g.back=j
}}for(var j=0;
j<K.length;
j++){if(K[j].flexAppUrl==M()&&j!=(h-2)){arbitraryUrl=true;
g.forward=j
}}E()
}D=document.location.href;
var m=M();
if(m==""){}if(typeof BrowserHistory_multiple!="undefined"&&BrowserHistory_multiple==true){var k=U();
for(var j=0;
j<k.length;
j++){k[j].browserURLChange(m)
}}else{O().browserURLChange(m)
}}}}function a(f){if(document.getElementsByName(f).length==0){Q().innerHTML+="<a name='"+f+"'>"+f+"</a>"
}}var c=function(){if(b.ie){var j=document.getElementsByTagName("script");
for(var n=0,q;
q=j[n];
n++){if(q.src.indexOf("history.js")>-1){var l=(new String(q.src)).replace("history.js","historyFrame.html")
}}H=l+"?";
var f=H;
var k=document.createElement("iframe");
k.id="ie_historyFrame";
k.name="ie_historyFrame";
try{document.body.appendChild(k)
}catch(o){setTimeout(function(){document.body.appendChild(k)
},0)
}}if(b.safari){var h=document.createElement("div");
h.id="safari_rememberDiv";
document.body.appendChild(h);
h.innerHTML='<input type="text" id="safari_remember_field" style="width: 500px;">';
var g=document.createElement("div");
g.id="safari_formDiv";
document.body.appendChild(g);
var p=document.createElement("div");
p.id="safarireloader";
var j=document.getElementsByTagName("script");
for(var n=0,q;
q=j[n];
n++){if(q.src.indexOf("history.js")>-1){html=(new String(q.src)).replace(".js",".html")
}}p.innerHTML='<iframe id="safarireloader-iframe" src="about:blank" frameborder="no" scrolling="no"></iframe>';
document.body.appendChild(p);
p.style.position="absolute";
p.style.left=p.style.top="-9999px";
k=p.getElementsByTagName("iframe")[0];
if(document.getElementById("safari_remember_field").value!=""){e=document.getElementById("safari_remember_field").value.split(",")
}}if(b.firefox){var m=document.createElement("div");
m.id="firefox_anchorDiv";
document.body.appendChild(m)
}};
return{historyHash:e,backStack:function(){return Y
},forwardStack:function(){return K
},getPlayer:O,initialize:function(f){c(f)
},setURL:function(f){document.location.href=f
},getURL:function(){return document.location.href
},getTitle:function(){return document.title
},setTitle:function(h){try{Y[Y.length-1].title=h
}catch(g){}if(b.safari){if(h==""){try{var f=window.location.href.toString();
h=f.substring((f.lastIndexOf("/")+1),f.lastIndexOf("#"))
}catch(g){h=""
}}}document.title=h
},setDefaultURL:function(j){C=j;
j=M();
if(b.ie){window._ie_firstload=true;
var f=H+j;
var h=function(){N().src=f;
window.location.replace("#"+j);
setInterval(R,50)
};
try{h()
}catch(k){window.setTimeout(function(){h()
},0)
}}if(b.safari){T=history.length;
if(e.length==0){e[T]=j;
var i="#"+j;
window.location.replace(i)
}else{}setInterval(R,50)
}if(b.firefox||b.opera){var g=new RegExp("#"+j+"$");
if(window.location.toString().match(g)){}else{var i="#"+j;
window.location.replace(i)
}setInterval(R,50)
}},setBrowserURL:function(j,f){if(b.ie&&typeof f!="undefined"){I=f
}var i=document.location.href.indexOf("#");
var g=i!=-1?document.location.href.substr(0,i):document.location.href;
var h=g+"#"+j;
if(document.location.href!=h&&document.location.href+"#"!=h){D=h;
d(g,h,j);
T=history.length
}return false
},browserURLChange:function(k){var f=null;
if(b.ie&&I!=null){f=I
}pendingURL="";
if(typeof BrowserHistory_multiple!="undefined"&&BrowserHistory_multiple==true){var h=U();
for(var g=0;
g<h.length;
g++){try{h[g].browserURLChange(k)
}catch(j){}}}else{try{O(f).browserURLChange(k)
}catch(j){}}I=null
}}
})();
function setURL(A){document.location.href=A
}function backButton(){history.back()
}function forwardButton(){history.forward()
}function goForwardOrBackInHistory(A){history.go(A)
}(function(i){var u=navigator.userAgent;
var e=
/*@cc_on!@*/
false;
var st=setTimeout;
if(/webkit/i.test(u)){st(function(){var dr=document.readyState;
if(dr=="loaded"||dr=="complete"){i()
}else{st(arguments.callee,10)
}},10)
}else{if((/mozilla/i.test(u)&&!/(compati)/.test(u))||(/opera/i.test(u))){document.addEventListener("DOMContentLoaded",i,false)
}else{if(e){(function(){var t=document.createElement("doc:rdy");
try{t.doScroll("left");
i();
t=null
}catch(e){st(arguments.callee,0)
}})()
}else{window.onload=i
}}}})(function(){BrowserHistory.initialize()
});
