/* <![CDATA[ */

if(!window.addNamespace){
	window.addNamespace=function(ns){
		var nsParts=ns.split('.'),l=nsParts.length,root=window,i=-1;
		for(var i=0,l=nsParts.length;i<l;++i){if(typeof root[nsParts[i]]==='undefined'){root[nsParts[i]]={};}root=root[nsParts[i]];}
	};
}
if(!window.Class){var Class={create:function(){return function(){if(typeof this.initialize==='function'){this.initialize.apply(this,arguments);}};}};}
(function(){ // hide from global scope
	// suppress errors in NN4.x (like try ... catch blocks)
	if(!document.getElementById&&document.layers){window.onerror=function(){if(window.__onerror){window.__onerror();}return true;};}

	if(!Object.extend){
		Object.extend=function extend(dest,source,override){for(prop in source){if(override||typeof dest[prop]==='undefined'){dest[prop]=source[prop];}}return dest;};
	}
	if(!Object.hasOwnProperty){
		Object.hasOwnProperty=function hasOwnProperty(property){
			try{var prototype=this.constructor.prototype;while(prototype){if(prototype[property]===this[property]){return false;}prototype=prototype.prototype;}}
			catch(e){}
			return true;
		};
	}
	Object.extend(String.prototype,{
		camelize:function(){
			var oStringList=this.split('-');
			if(oStringList.length==1){return oStringList[0];}
			var camelizedString=this.indexOf('-')===0?oStringList[0].charAt(0).toUpperCase()+oStringList[0].substring(1):oStringList[0];
			for(var i=1,len=oStringList.length;i<len;i++){
				var s=oStringList[i];
				camelizedString+=s.charAt(0).toUpperCase()+s.substring(1);
			}
			return camelizedString;
		},
		endsWith:function(s){return (this.substr(this.length-s.length)===s);},
		entityify:function(){return this.replace(/&/g,'&amp;').replace(/</g,'&lt;').replace(/>/g,'&gt;');},
		lTrim:function(){return this.replace(/^\s+/,'');},
		quote:function(){
			var c,i,l=this.length,o='"';
			for(i=0;i<l;i+=1){
				c=this.charAt(i);if(c>=' '){if(c==='\\'||c==='"'){o+='\\';}o+=c;}
				else{
					switch(c){
						case '\b':o+='\\b';break;case '\f':o+='\\f';break;case '\n':o+='\\n';break;case '\r':o+='\\r';break;case '\t':o+='\\t';break;
						default:c=c.charCodeAt();o+='\\u00'+Math.floor(c/16).toString(16)+(c%16).toString(16);
					}
				}
			}
			return o+'"';
		},
		rTrim:function(){return this.replace(/\s+$/,'');},
		startsWith:function(s){return (this.substring(0,s.length)===s);},
		supplant:function(o){
			var i,j,s=this,v;
			for(;;){
				i=s.lastIndexOf('{');if(i===-1){break;}j=s.indexOf('}',i);if(i+1>=j){break;}
				v=o[s.substring(i+1,j)];if((typeof v!=='string')&&((typeof v!=='number')||!isFinite(v))){break;}
				s=s.substring(0,i)+v+s.substring(j+1);
			}
			return s;
		},
		trim:function(){return this.lTrim().rTrim();}
	});

	Object.extend(Function.prototype,{
		apply:function(o,a){
			var r,x='____apply';if(typeof o!=='object'){o={};}o[x]=this;
			switch((a&&a.length)||0){
				case 0:r=o[x]();break;case 1:r=o[x](a[0]);break;case 2:r=o[x](a[0],a[1]);break;case 3:r=o[x](a[0],a[1],a[2]);break;case 4:r=o[x](a[0],a[1],a[2],a[3]);break;case 5:r=o[x](a[0],a[1],a[2],a[3],a[4]);break;case 6:r=o[x](a[0],a[1],a[2],a[3],a[4],a[5]);break;
				default:alert('Too many arguments to apply: '+a.length+'.');
			}try{delete o[x];}catch(e){o[x]=null;}return r;
		},
		fname:function(){var s;return (s=/function (\w+)/.exec(this.toString()))?s[1]:'(anonymous)';},
		inherits:function(parent){
			var d=0,p=(this.prototype=new parent());
			Object.extend(this.prototype,{
				uber:function(name){
					var f,r,t=d,v=parent.prototype;if(t){while(t){v=v.constructor.prototype;t-=1;}f=v[name];}else{f=p[name];if(f===this[name]){f=v[name];}}
					d+=1;r=f.apply(this,Array.prototype.slice.apply(arguments,[1]));d-=1;return r;
				}
			});
			return this;
		},
		method:function(name,func){this.prototype[name]=func;return this;},
		swiss:function(parent){for(var i=1,name;i<arguments.length;++i){name=arguments[i];this.prototype[name]=parent.prototype[name];}return this;}
	});

	// Mozilla 1.8 has support for every, filter, forEach, indexOf, lastIndexOf, map, some
	Object.extend(Array.prototype,{
		copy:function(){var a=[],i=-1,l=this.length;while((++i)<l){a[i]=this[i].copy?this[i].copy():this[i];}return a;},
		concat:function(a){var b=this.copy(),i=-1,l=a.length;while((++i)<l){b.push(a[i]);}return b;},
		every:function(f,obj){var i=-1,l=this.length;while((++i)<l){if(!f.call(obj,this[i],i,this)){return false;}}return true;},
		filter:function(f,obj){var i=-1,l=this.length,res=[];while((++i)<l){if(f.call(obj,this[i],i,this)){res.push(this[i]);}}return res;},
		forEach:function(f,obj){var i=-1,l=this.length;while((++i)<l){f.call(obj,this[i],i,this);}},
		indexOf:function(o,fromIndex){
			fromIndex=(fromIndex===null)?0:(fromIndex<0)?Math.max(0,this.length+fromIndex):fromIndex;
			var i=fromIndex,l=this.length;while((i++)<l){if(this[i]===obj){return i;}}return -1;
		},
		lastIndexOf:function(obj,fromIndex){
			fromIndex=(fromIndex===null)?this.length-1:(fromIndex<0)?Math.max(0,this.length+fromIndex):fromIndex;
			for(var i=fromIndex;i>=0;--i){if(this[i]===obj){return i;}}return -1;
		},
		map:function(f,obj){var i=-1,l=this.length,res=[];while((++i)<l){res.push(f.call(obj,this[i],i,this));}return res;},
		push:function(){var i=-1,l=arguments.length;while((++i)<l){this[this.length]=arguments[i];}return this.length;},
		pop:function(){var r=null;if(this.length){r=this[this.length-1];--this.length;}return r;},
		reverse:function(){var a=[],i=this.length;while(i){a.push(this[--i]);}return a;},
		shift:function(){var r=null;if(this.length){r=this.reverse().pop();this.reverse();}return r;},
		some:function(f,obj){var i=-1,l=this.length;while((++i)<l){if(f.call(obj,this[i],i,this)){return true;}}return false;},
		unshift:function(){this.reverse();var i=-1,l=arguments.length;while((++i)<l){this.push(arguments[i]);}this.reverse();return this.length;},
		splice:function(b,d){var m=b+d,af=this.slice(m),r=d>0?this.slice(b,m-1):[],i=1,l=arguments.length;while((++i)<l){af.unshift(arguments[i]);}if(b>0){this.slice(0,b).concat(af);}else{while(this.length){this.pop();}while(af.length){this.push(af.pop());}}return r;}
	});

})();

var Events,Win;
(function(){
	// mozilla equivalent for insertAdjacentElement and inner|outer HTML|Text in IE5+
	// workaround for Opera 8 (which doesn't handle __define[G|S]etter__)
	if(typeof HTMLElement!=='undefined'){
		if(!HTMLElement.prototype.outerHTML){
			if(window.opera){HTMLElement.prototype.outerHTML=function(s){return s?(document.documentElement.outerHTML=s):document.documentElement.outerHTML;};}
			else{
				HTMLElement.prototype.__defineGetter__('outerHTML',function(){var aA=this.attributes,eT=['area','base','basefont','br','col','frame','hr','img','input','isindex','link','meta','param'],cA=['checked','compact','declare','defer','disabled','ismap','multiple','nohref','noresize','noshade','nowrap','readonly','selected'],t=this.tagName.toLowerCase(),s='<'+t;for(var i=0,a=aA[i].name.toLowerCase(),p=cA.within(a,true),v=aA[i].value,l=aA.length;i<l;++i){s+=' '+a+'="'+((p>-1&&!v.length)?cA[p]:v)+'"';}s+=(eT.within(t))?' />':'>'+this.innerHTML+'</'+t+'>';return s;});
				HTMLElement.prototype.__defineSetter__('outerHTML',function(s){var r=this.ownerDocument.createRange();r.setStartBefore(this);var df=r.createContextualFragment(s);this.parentNode.replaceChild(df,this);return this;});
			}
		}
		if(!HTMLElement.prototype.innerText){
			if(window.opera){HTMLElement.prototype.innerText=function(s){return s?(document.documentElement.innerText=s):document.documentElement.innerText;};}
			else{
				HTMLElement.prototype.__defineGetter__('innerText',function(){var r=this.ownerDocument.createRange();r.selectNodeContents(this);return String(r);});
				HTMLElement.prototype.__defineSetter__('innerText',function(s){this.innerHTML=s.escapeHTML();return this;});
			}
		}
		if(!HTMLElement.prototype.outerText){
			if(window.opera){HTMLElement.prototype.outerText=function(s){return s?(document.documentElement.outerText=s):document.documentElement.outerText;};}
			else{
				HTMLElement.prototype.__defineGetter__('outerText',function(){return this.innerText();});
				HTMLElement.prototype.__defineSetter__('outerText',function(s){this.outerHTML=s.escapeHTML();return this;});
			}
		}
		if(!HTMLElement.prototype.insertAdjacentElement){
			HTMLElement.prototype.insertAdjacentElement=function(w,pN){switch(String(w).toLowerCase()){case 'afterbegin':this.insertBefore(pN,this.firstChild);break;case 'afterend':if(this.nextSibling){this.parentNode.insertBefore(pN,this.nextSibling);}else{this.parentNode.appendChild(pN);}break;case 'beforebegin':this.parentNode.insertBefore(pN,this);break;case 'beforeend':this.appendChild(pN);break;}return this;};
			HTMLElement.prototype.insertAdjacentHTML=function(w,S){var r=this.ownerDocument.createRange();switch(String(w).toLowerCase()){case 'beforebegin':r.setStartBefore(this);break;case 'beforeend':case 'afterbegin':r.selectNodeContents(this);r.collapse(false);break;case 'afterend':r.setStartAfter(this);break;}var pH=r.createContextualFragment(S);this.insertAdjacentElement(w,pH);return this;};
			HTMLElement.prototype.insertAdjacentText=function(w,s){this.insertAdjacentHTML(w,s.escapeHTML());return this;};
		}
	}
	Events=Events||{
		aeOL:[],
		Cancel:function(e,c){e.returnValue=false;if(e.preventDefault){e.preventDefault();}if(c){e.cancelBubble=true;if(e.stopPropagation){e.stopPropagation();}}return this;},
		ieMouse:function(n){return (/^mouseo(ut|ver)$/.test(n)&&window.attachEvent)?(/ver$/.test(n))?'mouseenter':'mouseleave':n;},
		operaObj:function(o,b){var d=(b?'add':'remove')+'EventListener';return (o===window&&!o[d]&&document[d])?document:o;}
	};
	Events.Add=document.addEventListener?(
		function(o,n,f,l){o=Events.operaObj(o,true);if(!l||(l&&typeof l!=='boolean')){l=new Boolean(false);}return o.addEventListener(n,f,l);}):(
		function(o,n,f,l){
			n=Events.ieMouse(n);var c='captureEvents',h='on'+n,t,a;if(!o.aE){o.aE=Events.aeOL.length||1;Events.aeOL[o.aE]={o:o};}t=Events.aeOL[o.aE][n]||(Events.aeOL[o.aE][n]=[]);
			for(var i=0;i<t.length;i++){for(var j=0;j<t[i].length;j++){if(t[i][j]==f){return true;}}}if(o[h]&&o[h]._ae){a=t[t.length-1];a[a.length]=f;}
			else{t[t.length]=o[h]?[o[h],f]:[f];o[h]=new Function('e','var r=true,i=0,o=Events.aeOL['+o.aE+'].o,a=Events.aeOL['+o.aE+'][\''+n+'\']['+(t.length-1)+'];for(;i<a.length;i++){o._f=a[i];r=o._f(e||window.event)!=false&&r;o._f=null;}return r;');if(o[c]){o[c](Event[n.toUpperCase()]);}o[h]._ae=1;}
			return true;}
	);
	Events.Remove=document.removeEventListener?(
		function(o,n,f,l){o=Events.operaObj(o);if(!l||(l&&typeof l!=='boolean')){l=new Boolean(false);}return o.removeEventListener(n,f,l);}):(
		function(o,n,f,l){n=Events.ieMouse();var c='releaseEvents',t,a,i,j,s;if(!o.aE||!Events.aeOL[o.aE]||!Events.aeOL[o.aE][n]){return true;}t=Events.aeOL[o.aE][n];i=t.length;while(i--){a=t[i];s=0;j=a.length;while(j--){if(a[j]==f){s=1;}if(s){a[j]=a[j+1];}}if(s){a.length--;break;}}if(!i){Events.aeOL[o.aE][n]=o.aE=o[h]=null;if(o[c]){o[c](Event[n.toUpperCase()]);}}return true;}
	);
	Win=Win||{ss:function(s){window.status=s;return true;},cs:function(){return Win.ss('');}};
})();

(function(){
if(!document.getElementById){document.getElementById=new Function('id','f','if(document.layers){f=f||self;if(f.document.layers[id]){return f.document.layers[id];}for(var W=0,t;W<f.document.layers.length;++W){t=document.getElementById(id,f.document.layers[W]);}return t;}if(document.all&&document.all[id]){return document.all[id];}return null;');}
if(!document.getElementsByTagName){document.getElementsByTagName=function(tag){var r=[];if(document.all){if(tag==='*'){return document.all;}var i=-1,el;while((el=document.all[++i])){if(el.tagName.toLowerCase()===tag.toLowerCase()){r.push(el);}}}return r.length?r:null;};}
if(!document.forms){
	document.getFormById=document.getElementById;
	document.getFormElementById=document.getElementById;
}
else{
	document.getFormById=function(s){
		var l=document.forms.length,r=null;
		while(l--&&!r){
			if((document.forms[l].id==s)||(document.forms[l].name==s)){r=document.forms[l];}
		}
		return r;
	};
	document.getFormElementById=function(s){
		var l=document.forms.length,fl,r=null;
		while(l--&&!r){
			fl=document.forms[l].length;
			while(fl--&&!r){
				if((document.forms[l][fl].id==s)||(document.forms[l][fl].name)==s){r=document.forms[l][fl];}
			}
		}
		return r;
	};
}
document.getFormLabelById=function(s){
	var r=null;
	if(document.getFormElementById(s)){
		var labels=document.getElementsByTagName('label'),l=labels.length;
		while(l--&&!r){
			if((labels[l].htmlFor||labels[l].getAttribute('for'))==s){r=labels[l];}
		}
	}
	return r;
};
})();

(function(){
addNamespace('com.deconcept');
Object.extend(com.deconcept,{
	ActiveX:{
		AdobeSVG:{re:'type="?image/svg\\+xml"?',classid:'78156A80-C6A1-4BBF-8E6A-3CD390EEB4E2',codebase:'http://www.adobe.com/svg/viewer/install/'},
		Flash:{re:'type="?application/x-shockwave-flash"?',classid:'D27CDB6E-AE6D-11CF-96B8-444553540000',codebase:'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0'},
		Java:{re:'type="?application/x-java-',classid:'8AD9C840-044E-11D1-B3E9-00805F499D93',codebase:'http://java.sun.com/products/plugin/autodl/jinstall-1_4_2-windows-i586.cab#Version=1,4,2,0'},
		Quicktime:{re:'type="?video/quicktime"?',classid:'02BF25D5-8C17-4B23-BC80-D3488ABDDC6B',codebase:'http://www.apple.com/qtactivex/qtplugin.cab'},
		RealPlayer:{re:'type="?audio/x-pn-realaudio-plugin"?',classid:'CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA',codebase:'http://uk.real.com/player/?lang=en&loc=gb&src=ZG.uk.home.realplayer_rm_split.760.realplayer_rm_split'},
		WindowsMedia:{re:'type="?application/x-mplayer2"?',classid:'22D6F312-B0F6-11D0-94AB-0080C74C7E95',codebase:'http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,7,1112'},
		WindowsMedia7:{re:'type="?application/x-oleobject"?',classid:'6BF52A52-394A-11d3-B153-00C04F79FAA6',codebase:'http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=7,0,0,1954'}
	},
	Base:{
		createParamTag:function(n,v){var p=document.createElement('param');p.setAttribute('name',n);p.setAttribute('value',v);return p;},
		getAttribute:function(name){return com.deconcept.Core.getValue(this.attributes,name);},getAttributes:function(){return this.attributes;},
		getHTMLAttributes:function(){return this.htmlAttributes;},getHTMLAttributePairs:function(){return com.deconcept.Core.getPairs(this.htmlAttributes);},
		getParam:function(name){return com.deconcept.Core.getValue(this.params,name);},
		getParams:function(){return this.params;},getParamPairs:function(tag){return com.deconcept.Core.getPairs(this.getParams(),tag);},
		getVariable:function(name){return com.deconcept.Core.getValue(this.variables,name);},
		getVariables:function(){return this.variables;},getVariablePairs:function(){return com.deconcept.Core.getPairs(this.getVariables());},
		setAttribute:function(name,value){com.deconcept.Core.setValue(this.attributes,name,value);},
		setHTMLAttribute:function(name,value){com.deconcept.Core.setValue(this.htmlAttributes,name,value);},
		setParam:function(name,value){com.deconcept.Core.setValue(this.params,name,value);},
		setVariable:function(name,value){com.deconcept.Core.setValue(this.variables,name,value);}
	},
	Core:{
		getPairs:function(values,tag){
			var pairs=[],key;for(key in values){pairs.push(tag?'<'+'param name="'+key+'" value="'+values[key]+'" /'+'>':key+'="'+values[key]+'"');}return pairs.sort();
		},
		getRequestParameter:function(param){
			var q=document.location.search,s='';
			if(q){
				var startIndex=q.indexOf(param+'='),endIndex=(q.indexOf('&',startIndex)!==-1)?q.indexOf('&',startIndex):q.length;
				if((q.length>1)&&(startIndex!==-1)){s=q.substring(q.indexOf('=',startIndex)+1,endIndex);}
			}
			return s;
		},
		getValue:function(values,name){return (values&&values[name])?values[name]:'';},
		removeChildren:function(n){while(n.hasChildNodes()){n.removeChild(n.firstChild);}},
		setObject:function(obj,src,id,w,h,useExpressInstall,xiRedirectUrl,redirectUrl,detectKey){
			Object.extend(obj,{attributes:[],htmlAttributes:{},params:{},variables:{}},true);
			if(src){obj.setAttribute('src',src);}if(id){obj.setAttribute('id',id);}if(w){obj.setAttribute('width',w);}if(h){obj.setAttribute('height',h);}
			obj.useExpressInstall=useExpressInstall;
			obj.setAttribute('xiRedirectUrl',xiRedirectUrl||window.location);obj.setAttribute('redirectUrl',redirectUrl||'');
			obj.skipDetect=detectKey?com.deconcept.Core.getRequestParameter(detectKey):true;
			if(!obj.skipDetect.length){obj.skipDetect=true;}
		},
		setValue:function(values,name,value){values[name]=value;}
	},
	PlayerVersion:function(ver){Object.extend(this,{major:parseInt(ver[0],10)||0,minor:parseInt(ver[1],10)||0,rev:parseInt(ver[2],10)||0},true);}
},true);

Object.extend(com.deconcept.PlayerVersion.prototype,{
	versionIsValid:function(fv){
		if(this.major<fv.major){return false;}if(this.major>fv.major){return true;}if(this.minor<fv.minor){return false;}if(this.minor>fv.minor){return true;}
		if(this.rev<fv.rev){return false;}return true;
	}
},true);

Object.extend(com.deconcept,{
	FlashObject:function(src,id,w,h,ver,c,useExpressInstall,quality,xiRedirectUrl,redirectUrl,detectKey){
		if(!document.createElement||!document.getElementById){return;}
		com.deconcept.Core.setObject(this,src,id,w,h,useExpressInstall,xiRedirectUrl,redirectUrl,detectKey||'detectflash');
		if(ver){this.setAttribute('version',new com.deconcept.PlayerVersion(ver.toString().split('.')));}if(c){this.setParam('bgcolor',c);}
		this.setParam('quality',quality||'high');this.installedVer=com.deconcept.FlashObjectUtil.getVersion(this.getAttribute('version'),useExpressInstall);
		this.preHTML='';this.postHTML='';
	},
	FlashObjectUtil:{
		getVersion:function(reqVer,xiInstall){
			if(navigator.plugins&&navigator.mimeTypes.length){
				var x=navigator.plugins['Shockwave Flash'];
				if(x&&x.description){FlashVersion=new com.deconcept.PlayerVersion(x.description.replace(/([a-z]|\s)+/i,'').replace(/\s+(r|b[0-9]+)/,'.').split('.'));}
			}
			else{
				function ver(){
					if(this.version){return this.version;}this.version=new com.deconcept.PlayerVersion(0,0,0);
					try{
						var axo=new ActiveXObject('ShockwaveFlash.ShockwaveFlash'),i=3;
						while((axo=new ActiveXObject('ShockwaveFlash.ShockwaveFlash.'+i))){this.version=new com.deconcept.PlayerVersion([i++,0,0]);}
					}catch(e){}return this.version;
				}
				var FlashVersion=ver();
				if(reqVer&&FlashVersion.major>reqVer.major){return FlashVersion;} // version is ok, skip minor detection
				// this only does the minor rev lookup if the user's major version 
				// is not 6 or we are checking for a specific minor or revision number
				// see http://blog.deconcept.com/2006/01/11/getvariable-setvariable-crash-internet-explorer-flash-6/
				if(!reqVer||(((reqVer.minor!==0)||(reqVer.rev!==0))&&(FlashVersion.major===reqVer.major))||FlashVersion.major!==6||xiInstall){
					try{FlashVersion=new com.deconcept.PlayerVersion(axo.GetVariable('$version').split(' ')[1].split(','));}catch(e){}
				}
			}
			return FlashVersion;
		}
	}
},true);

Object.extend(Object.extend(com.deconcept.FlashObject.prototype,com.deconcept.Base,true),{
	getHTML:function(){
		var html='',params,pairs;
		if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){ // netscape plugin architecture
			if(this.getAttribute('doExpressInstall')){this.setVariable('MMplayerType','PlugIn');}
			html='<embed height="'+this.getAttribute('height')+'" id="'+this.getAttribute('id')+'" name="'+this.getAttribute('id')+'" src="'+this.getAttribute('src')+'" type="application/x-shockwave-flash" width="'+this.getAttribute('width')+'"';
			params=this.getParamPairs().join(' ');if(params.length){html+=params;}pairs=this.getVariablePairs().join('&');if(pairs.length){html+=' flashvars="'+ pairs +'"';}
			html+=' />';
		}
		else{ // PC IE
			var attrs=this.getHTMLAttributes();
			if(this.getAttribute('doExpressInstall')){this.setVariable('MMplayerType','ActiveX');}
			if(!attrs.classid){this.setHTMLAttribute('classid','clsid:'+com.deconcept.ActiveX.Flash.classid);}
			if(!attrs.codebase){this.setHTMLAttribute('codebase',com.deconcept.ActiveX.Flash.codebase);}
			if(!attrs.data){this.setHTMLAttribute('data',this.getAttribute('src'));}
			if(!attrs.height&&(this.getAttribute('height')!==0)){this.setHTMLAttribute('height',this.getAttribute('height'));}
			if(!attrs.width&&(this.getAttribute('width')!==0)){this.setHTMLAttribute('width',this.getAttribute('width'));}
			pairs=this.getVariablePairs().join('&');if(pairs.length){this.setParam('flashvars',pairs);}
			this.setParam('movie',this.getAttribute('src'));
			html='<'+'object '+this.getHTMLAttributePairs().join(' ')+'>'+this.getParamPairs(true).join('');
			if(this.subHTML.length){html+=this.subHTML;}
			html+='</'+'object>';
		}
		return html;
	},
	write:function(elementId){
		if(this.useExpressInstall){ // check to see if we need to do an express install
			var expressInstallReqVer=new com.deconcept.PlayerVersion([6,0,65]);
			if(this.installedVer.versionIsValid(expressInstallReqVer)&&!this.installedVer.versionIsValid(this.getAttribute('version'))){
				this.setAttribute('doExpressInstall',true);this.setVariable('MMredirectURL',escape(this.getAttribute('xiRedirectUrl')));
				document.title=document.title.slice(0,47)+' - Flash Player Installation';this.setVariable('MMdoctitle',document.title);
			}
		}
		else{this.setAttribute('doExpressInstall',false);}
		if(this.skipDetect||this.getAttribute('doExpressInstall')||this.installedVer.versionIsValid(this.getAttribute('version'))){
			((typeof elementId==='string')?document.getElementById(elementId):elementId).innerHTML=this.preHTML+this.getHTML()+this.postHTML;
		}
		else{if(this.getAttribute('redirectUrl')!==''){document.location.replace(this.getAttribute('redirectUrl'));}}
	}
},true);

addNamespace('HTMLString');
Object.extend(HTMLString,{
	getAttributes:function(s){
		var r={},b=false,bq=false;
		for(var i=0,l=s.length,n='',v='',t;i<l;++i){
			t=s.charAt(i);
			switch(t){
				case '=':if(b){v+=t;}else{b=true;}break;
				case ' ':if(bq){v+=t;}else{b=false;}break;
				case '"':bq=!bq;break;
				default:if(b){v+=t}else{n+=t;}break;
			}
			if(!b&&v.length||(i===(l-1))){r[n]=v;n='';v='';}
		}
		return r;
	},
	getParams:function(obj){
		var params=obj.getElementsByTagName('param'),r=[];
		if(params.length){
			for(var i=0,h,l=params.length,p;i<l;++i){if(params[i].parentNode===obj){
				h=params[i].outerHTML;h=h.substring(h.indexOf(' '),h.length-(h.endsWith('/>')?2:1)).trim();
				p=HTMLString.getAttributes(h);r[p.name]=p.value;
			}}
		}
		return r;
	}
});

addNamespace('ActiveX');
Object.extend(ActiveX,{
	fix:function(){
		function wrap(obj,pre){
			var pH=objects[i].parentNode.innerHTML,h=obj.outerHTML;
			if(pre){return pH.substr(0,pH.indexOf(h)).trim();}else{return pH.substr(pH.indexOf(h)+(h.length-1)).trim();}
		}
		if(!document.getElementsByTagName){return;}
		var objects=document.getElementsByTagName('object'),attrs,type='',prop;
		if(objects.length){
			var i=objects.length;
			while(i--){
				attrs=objects[i].outerHTML.substring(objects[i].outerHTML.indexOf(' '),objects[i].outerHTML.indexOf('>')).trim();
				for(var axO in com.deconcept.ActiveX){if(attrs.match(new RegExp(com.deconcept.ActiveX[axO].re,'i'))){type=axO;break;}}
				if(type.length){
					attrs=HTMLString.getAttributes(attrs);
					if(!objects[i].id||!objects[i].id.length){objects[i].id='autogen_object_'+i;attrs['id']=objects[i].id;}
					if(!objects[i].parentNode.id||!objects[i].parentNode.id.length){objects[i].parentNode.id='autogen_replace_'+i;}
					var obj=null,pA=null,props=ActiveX.getProperties(objects[i]);
					switch(type){
						case 'Flash':
							pA=HTMLString.getParams(objects[i]);props.bgcolor=pA['bgcolor']||null;
							obj=new com.deconcept.FlashObject(props.src,props.id,props.width,props.height,7,props.bgcolor);
							break;
					}
					if(obj!==null){
						for(prop in attrs){obj.setHTMLAttribute(prop,attrs[prop]);}
						if(pA.constructor===Array){for(prop in pA){if(typeof pA[prop]==='string'){obj.setParam(prop,pA[prop]);}}}
						obj.subHTML=objects[i].innerHTML.trim();obj.preHTML=wrap(objects[i],true);obj.postHTML=wrap(objects[i]);obj.write(objects[i].parentNode.id);
					}
				}
			}
		}
	},
	getProperties:function(obj){
		return {height:parseInt(obj.getAttribute('height'),10)||0,id:obj.getAttribute('id'),src:obj.getAttribute('data'),width:parseInt(obj.getAttribute('width'),10)||0};
	}
},true);
})();

(function(){
addNamespace('FormBehaviour');
Object.extend(FormBehaviour,{
	forms:[],
	apply:function(){
		var form,field,el,l=FormBehaviour.forms.length;if(l===0){return;}
		while((form=FormBehaviour.forms[--l])){
			for(field in form.fields){
				if((el=document.getFormElementById(field))){
					switch(el.type){
						case 'file':break;
						case 'password':case 'text':case 'textarea':{
							el.defaultText=form.fields[field].defaultText;
							if(form.fields[field].useDefault){$(el).focus(FormBehaviour.checkText).blur(FormBehaviour.checkText);}
							else{if(el.value==el.defaultText){el.value='';}}
						}
						case 'select-one':case 'select-multiple':break;
					}
					if(form.fields[field].required){el.required=true;}
				}
			}
			$(document.getFormById(form.name)).submit(FormBehaviour.submit);
		}
	},
	checkText:function(event){
		var t=event.target||event.srcElement;
		switch(event.type){
			case 'focus':if(t.value==t.defaultValue){t.value='';}break;
			case 'blur':if(t.value==''){t.value=t.defaultValue;}break;
		}
	},
	register:function(form){FormBehaviour.forms.push(form);},
	submit:function(event){
		var t=(event.target||event.srcElement),form,l=FormBehaviour.forms.length,valid=true,errArr=[],found=false;
		while((form=FormBehaviour.forms[--l])&&!found){
			found=((t.id==form.name)||(t.name==form.name));
			if(found){
				for(var field in form.fields){
					field=document.getFormElementById(field);
					if(field.required){
						switch(field.type){
							case 'file':break;
							case 'password':case 'text':case 'textarea':{
								if(field.value.replace(field.defaultText,'').length===0){
									errArr.push(document.getFormLabelById(field.id||field.name).innerText);
									valid=false;
								}
							}
							case 'select-one':case 'select-multiple':break;
						}
					}
				}
				if(!valid){
					event.preventDefault();
					errArr.unshift(((form.errorText&&form.errorText.length)?form.errorText:'Please complete the required fields')+':\n');
					alert(errArr.join('\n'));
				}
			}
		}
	}
},true);
})();

(function(){
addNamespace('WindowBehaviour');
Object.extend(WindowBehaviour,{
	links:[],
	windows:[],
	apply:function(){
		var win,l=WindowBehaviour.windows.length;if(l===0){return;}
		var tA=document.links,al=tA.length;
		while(al--){
			if(/\bpopup\b/i.test(tA[al].rel)){WindowBehaviour.links.push(tA[al]);}
		}
		if(WindowBehaviour.links.length===0){return;}
		while((win=WindowBehaviour.windows[--l])){
			al=WindowBehaviour.links.length;
			while(al--){
				if(WindowBehaviour.links[al].href.replace('&','&amp;')==win.href){
					Events.Add(WindowBehaviour.links[al],'click',WindowBehaviour.popup);
					break;
				}
			}
		}
	},
	popup:function(event){
		var t=event.target||event.srcElement,win,l=WindowBehaviour.windows.length;
		if(t.tagName.toLowerCase()!='a'){while(!(/a/i.test(t.tagName))){t=t.parentNode;}}
		Events.Cancel(event);
		while((win=WindowBehaviour.windows[--l])){
			if(t.href.replace('&','&amp;')==win.href){
				MM_openBrWindow(t.href,win.name,win.metrics);
				break;
			}
		}
	},
	register:function(win){WindowBehaviour.windows.push(win);}
},true);
})();

var Scroller=function(container,pause,step,tick){
	this.container=container||'';this.pause=pause?parseInt(pause,10):4000;this.step=step?parseInt(step,10):-1;this.tick=tick?parseInt(tick,10):100;
	this.autopause=true;this.bgcolor='#FFF';this.currBase='canvas';this.direction='vert';this.height=50;this.useOpacity=true;
	var self=this,content=[],currObj='',index=0;self.moveTimer=null;self.waitTimer=null;
	function init(){
		if(self.container.length&&document.getElementById(self.container)&&!document.getElementById(self.currBase)){
			currObj=self.currBase+'0';var o=document.getElementById(currObj),i=2;
			if(!o){setContent();o=document.getElementById(currObj);}
			if(o){
				while(i--){o=document.getElementById(self.currBase+i);o.style.backgroundColor=self.bgcolor;}
				if(self.autopause){
					o=document.getElementById(self.currBase);
					$(o).mouseover((function(){stop(true);}));
					$(o).mouseout((function(){self.waitTimer=window.setTimeout(function(){swap();},750);}));
				}
				if(self.step===-1){self.step=Math.floor(self.height/5);}
			}
		}
	}
	function move(){
		var o=document.getElementById(currObj),curpos=parseInt(o.style[self.direction==='vert'?'top':'left'],10);
		if(curpos>0){o.style[self.direction==='vert'?'top':'left']=Math.max(curpos-self.step,0)+'px';}else{stop();}
	}
	function setContent(){
		if(typeof self.height==='string'){self.height=parseInt(self.height,10);}var c=document.getElementById(self.container);
		if(c){
			c.style.overflow='hidden';var items=c.getElementsByTagName('ul')[0],item,i=-1;while((item=items.getElementsByTagName('li')[++i])){content.push(item.innerHTML);}
			if(content.length){
				if(document.createElement&&c.removeChild){c.removeChild(items);var can=document.createElement('div'),o=document.createElement('div');can.id=self.currBase;can.style.height=self.height+'px';o.id=self.currBase+'0';can.appendChild(o);o=document.createElement('div');o.id=self.currBase+'1';can.appendChild(o);c.appendChild(can);}
				else{var s=c.innerHTML.replace(/[\n\r\t]/g,'');c.innerHTML=s.substr(0,s.toUpperCase().indexOf('<UL>'))+'<div id="'+self.currBase+'"><div id="'+self.currBase+'0"></div><div id="'+self.currBase+'1"></div></div>';}
			}
		}
	}
	function start(b){if(b){self.moveTimer=window.setInterval(function(){move();},self.tick);}else{self.waitTimer=window.setTimeout(function(){swap();},self.pause);}}
	function stop(b){
		var o=document.getElementById(currObj);
		if(self.moveTimer){
			window.clearInterval(self.moveTimer);self.moveTimer=null;
			currObj=self.currBase+(currObj.endsWith('0')?'1':'0');index=(index<(content.length-1))?index+1:0;if(self.useOpacity){setOpacity(o,100);setOpacity(currObj,0);}
		}
		if(self.waitTimer){window.clearTimeout(self.waitTimer);self.waitTimer=null;}
		if(b){o.style[self.direction==='vert'?'top':'left']=0+'px';}else{start();}
	}
	function swap(){
		var o=document.getElementById(currObj),i=2;
		if(self.direction==='vert'){o.style.top=self.height+'px';o.style.left='0px';}else{o.style.top='0px';o.style.left=self.width+'px';}
		o.innerHTML=content[index];o.style.zIndex++;
		while(i--){if(self.useOpacity){setOpacity(self.currBase+i,20);}document.getElementById(self.currBase+i).style.zIndex=0;}
		start(true);
	}
	this.Start=function(){init();swap();};
};

function setOpacity(what,percent){
	if(typeof what==='string'){what=document.getElementById(what)||null;}if(!what){return false;}
	if(what.filters){if(!what.filters.alpha){what.style.filter='alpha(opacity=0);';}what.filters.alpha.opacity=parseInt(percent,10);}
	else{var oS=(typeof what.style.MozOpacity==='string')?'MozOpacity':(typeof what.style.opacity==='string')?'opacity':null;if(oS){what.style[oS]=(parseInt(percent,10)/100);}}return this;
};

var __Browser=function(){
	var self=this;this.__parseInt=function(x,r){return isNaN(r=parseInt(x,10))?0:r;};this.__db=(document.compatMode&&document.compatMode.toLowerCase()!='backcompat'||document.documentElement)?document.documentElement:(document.body||null);this.__n6=!!((typeof window.getComputedStyle!=='undefined')&&(typeof document.createRange!=='undefined'));
	this.Opera=!!(window.opera);this.OperaVer=this.Opera?!!(window.getSelection)?9:!!(opera.defineMagicFunction)?8:!!(opera.version)?7.6:!!(document.createComment)?7:!!(opera.buildNumber)?6:5:0;
	this.IE=!!(document.all&&!self.Opera&&self.__db&&(/microsoft/i.test(navigator.appName)));this.IEVer=self.IE?(/mac/i.test(navigator.platform))?5.2:!!(document.createComment)?6:!!(document.fireEvent)?5.5:!!(document.getElementById)?5:4:0;this.IEMac=!!(self.IE&&(self.IEVer===5.2));
	this.w3c=!!(!self.Opera&&!self.IE&&!self.__n6&&document.getElementById);this.NN4=!!(!self.w3c&&document.layers&&(typeof document.classes!=='undefined'));this.Safari=!!(!document.all&&document.childNodes&&!navigator.taintEnabled);this.px=self.NN4?'':'px';this.tiv=self.w3c?40:10;
	this.window={
		height:self.__parseInt((self.__db&&!self.Opera&!self.w3c&&self.__db.clientHeight)?self.__db.clientHeight:(window.innerHeight||0)),
		scroll:{x:self.__parseInt(window.pageXOffset||(self.__db?self.__db.scrollLeft:0)),y:self.__parseInt(window.pageYOffset||(self.__db?self.__db.scrollTop:0))},
		width:self.__parseInt((self.__db&&!self.Opera&&!self.w3c&&self.__db.clientWidth)?self.__db.clientWidth:(window.innerWidth||0))
	};
};
var Browser=new __Browser();

/* Run on DOM loaded code */
/* this is the function that will run */
$(document).ready((function(){
	//if(Browser.IEMac||Browser.NN4){return;} // we don't run script on IE5.2/Mac or NN4...
	if(window.ActiveXObject&&document.all){ActiveX.fix();}
	if(window.startScroller){startScroller();}
	$('#logobar').css({'cursor':'pointer'}).keypress((function(){document.location.href='/';})).click((function(){document.location.href='/';}));
	$('a').each((function(){
		if(/\bexternal\b/i.test(this.rel||this.getAttribute('rel'))){this.target='_blank';}
		if(typeof this.onkeypress=='function'){
			this.click(this.onkeypress);
		}
	}));
	FormBehaviour.apply();
	WindowBehaviour.apply();
	setStatus();
}));

/* user functions */
function ss(w){window.status=w;return true;}
function cs(){window.status='';return true;}

function setStatus(){
	var oA=['clientHref','backHref'],oS=['Login to client extranet','Previous page'],oC=['','history.back();'];
	for(var i=0,o;i<oA.length;++i){
		o=document.getElementById(oA[i]);
		if(o){
			o.onmouseover=new Function('return Win.ss(\''+oS[i].replace('\'','\\\'')+'\');');
			Events.Add(o,'mouseout',new Function('return Win.cs();'));
			if(oC[i].length){Events.Add(o,'click',new Function(oC[i]));}
		}
	}
	
}
function MM_openBrWindow(theURL,winName,features){var popWin=window.open(theURL,winName,features);popWin.focus();return false;}
function getStyle(element,style){
	if(typeof element=='string'){element=document.getElementById(element);}
	var value=element.style[style.camelize()];
	if(!value){
		if(document.defaultView&&document.defaultView.getComputedStyle){
			var css=document.defaultView.getComputedStyle(element,null);
			value=css?css.getPropertyValue(style):null;
		}
		else if(element.currentStyle){value=element.currentStyle[style.camelize()];}
	}
	if(window.opera&&(/left|top|right|bottom$/i.test(style))){
		if(Element.getStyle(element,'position')=='static'){value = 'auto';}
	}
	return value=='auto'?null:value;
}
function setStyle(element,style){
	if(typeof element=='string'){element=document.getElementById(element);}
	if(element){
		for (name in style){
	      element.style[name.camelize()]=style[name];
	    }
	}
}

/* ]]> */