/* -- Adobe GoLive JavaScript Library */

CSInit = new Array;
function CSScriptInit() {
if(typeof(skipPage) != "undefined") { if(skipPage) return; }
idxArray = new Array;
for(var i=0;i<CSInit.length;i++)
	idxArray[i] = i;
CSAction2(CSInit, idxArray);}
CSStopExecution=false;
function CSAction(array) {return CSAction2(CSAct, array);}
function CSAction2(fct, array) { 
	var result;
	for (var i=0;i<array.length;i++) {
		if(CSStopExecution) return false; 
		var aa = fct[array[i]];
		if (aa == null) return false;
		var ta = new Array;
		for(var j=1;j<aa.length;j++) {
			if((aa[j]!=null)&&(typeof(aa[j])=="object")&&(aa[j].length==2)){
				if(aa[j][0]=="VAR"){ta[j]=CSStateArray[aa[j][1]];}
				else{if(aa[j][0]=="ACT"){ta[j]=CSAction(new Array(new String(aa[j][1])));}
				else ta[j]=aa[j];}
			} else ta[j]=aa[j];
		}			
		result=aa[0](ta);
	}
	return result;
}
CSAct = new Object;
/* 
Fix Layer Position 1.0
A component of MenuMachine 2.1
Copyright 2006 Big Bang Software Pty Ltd
*/
/*begin FixLayerPosition*/
function __bbFLP(el,s,amt)
	{
	if(typeof(__bbElCache[el])=="undefined"){__bbElCache[el]=__bbgID(el);}
	var d=document,e=__bbElCache[el],mvAmt=0,sOf=__bbGST(),targetPos=e.origPos+sOf;
	if(e.currentPos!=targetPos){if(s){var diff=e.currentPos-targetPos;mvAmt=(Math.abs(diff)<amt)?-diff:((diff>0)?-amt:amt);mvAmt=(Math.abs(diff)>(amt*4))?mvAmt+mvAmt:mvAmt;var mtp=(e.currentPos+=mvAmt)+_bbBr.px;_bbBr.op?e.style.pixelTop=mtp:e.style.top=mtp;e.currentPos+=mvAmt;}
	else{var mtp=targetPos+_bbBr.px;_bbBr.op?e.style.pixelTop=mtp:e.style.top=mtp;e.currentPos=targetPos;}}
	};
function bbFixLayer(action)
	{
	var n=action[1],sm=action[2],spd=action[3],tks,px;
	if(!sm){tks=10;px=100;}
	else{if(!spd)spd="m";switch(spd){case "f":tks=10;px=20;break;case "m":tks=20;px=4;break;case "s":tks=30;px=2;break;}}
	var d=document,ua=navigator.userAgent.toLowerCase();function o(n){return (ua.indexOf("opera "+n)>-1||ua.indexOf("opera/"+n)>-1)&&window.opera?1:0};
	_bbBr.op5=o(5);_bbBr.op6=o(6);_bbBr.op=(_bbBr.op5||_bbBr.op6||window.opera)?1:0;
	_bbBr.ie=(ua.indexOf('msie')!=-1&&!_bbBr.op)?1:0;_bbBr.dt=(ua.indexOf("mac")==-1&&((d.doctype&&d.doctype.name&&d.doctype.name.indexOf("http:\/\/")>-1)||(d.compatMode&&(d.compatMode!="BackCompat"&&d.compatMode!="QuirksMode"))))?1:0;
	_bbBr.px=_bbBr.op?"":"px";var el=__bbgID(n);if(!el)return;el.origPos=__bbyP(el);el.currentPos=el.origPos-__bbGST();setInterval("__bbFLP('"+n+"',"+sm+","+px+");",tks);
	};
function __bbyP(o){var c=0;if (o.offsetParent){while (o.offsetParent){c+=o.offsetTop;o=o.offsetParent;}}else if(o.y){c+=o.y;} return c;};
function __bbGST(){return _bbBr.ie?(_bbBr.dt?document.documentElement.scrollTop:document.body.scrollTop):window.pageYOffset;};
function __bbgID(i){if(document.getElementById){return document.getElementById(i);}else if(document.all){return document.all[i];}else{return false;}};
var __bbElCache=[],_bbBr={};
/*end FixLayerPosition*/
function CSshowtimedateID(action) {
	(action[2] != "") ? (updateobject = action[2]) : (updateobject = action[1])
	showtime = action[3]
	usemilitary = action[4]
	showdate = action[5]
	dateformat = action[6]
	showday = action[7]
	leadin = action[8]
	opentag = action[9]
	closetag = action[10]
	theTimer = setTimeout("theClockDate()",10);
}

function theClockDate() {   
	now = new Date()
	theMonth = now.getMonth() + 1
	theDate = now.getDate()
	theYear = now.getFullYear()
	theDay = now.getDay()
	hours = now.getHours()
	if(navigator.appVersion.indexOf("MSIE 5; Macintosh") != -1) {
	if (theMonth <= 11 && theMonth >= 4) { hours = hours + 1}
	}
	ampm = ((hours >= 12) ? "PM" : "AM");
	hours = ((hours > 12 && usemilitary == false) ? hours -12 : hours);
	if (hours == 0) hours = 12;
	if (hours >= 1 && hours <=9) hours = "0" + hours;
	minutes = now.getMinutes()
	if (minutes < 10) minutes = "0" + minutes;
	time = "";
	(showtime == true) ? (time = " " + hours + ":" + minutes) : (time = "",ampm="");
	(usemilitary == true) ? (ampm="") : (ampm=ampm);
	days = new Array("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday");
	today = days[theDay];
	if (showdate == true) {
		if (dateformat == 0) todisplay = theMonth + "/" + theDate + "/" + theYear;
		if (dateformat == 1) todisplay = theDate + "/" + theMonth + "/" + theYear;
		if (dateformat == 2) todisplay = theYear + "/" + theMonth + "/" + theDate;
		if (dateformat == 3) todisplay = theYear + "/" + theDate + "/" + theMonth;
		} else {todisplay = "" }
	if (showday == true) todisplay =  today + ", " + todisplay;
	if (document.all) { document.all(updateobject).innerHTML = opentag + leadin + todisplay + time + " " + ampm + closetag; } 
	else {
		if (document.getElementById) { document.getElementById(updateobject).innerHTML = opentag + leadin + todisplay + time + " " + ampm + closetag; }
}
theTimer = setTimeout("theClockDate()",2000);
}
function CSOpenWindow(action) {
	var wf = "";	
	wf = wf + "width=" + action[3];
	wf = wf + ",height=" + action[4];
	wf = wf + ",resizable=" + (action[5] ? "yes" : "no");
	wf = wf + ",scrollbars=" + (action[6] ? "yes" : "no");
	wf = wf + ",menubar=" + (action[7] ? "yes" : "no");
	wf = wf + ",toolbar=" + (action[8] ? "yes" : "no");
	wf = wf + ",directories=" + (action[9] ? "yes" : "no");
	wf = wf + ",location=" + (action[10] ? "yes" : "no");
	wf = wf + ",status=" + (action[11] ? "yes" : "no");		
	window.open(action[1],action[2],wf);
}
function CSClickReturn () {
	var bAgent = window.navigator.userAgent; 
	var bAppName = window.navigator.appName;
	if ((bAppName.indexOf("Explorer") >= 0) && (bAgent.indexOf("Mozilla/3") >= 0) && (bAgent.indexOf("Mac") >= 0))
		return true; /* dont follow link */
	else return false; /* dont follow link */
}
