﻿// JScript File

function detectPopupBlocker() {
		if ( Get_Cookie( 'popupsenabled' ) ) return;

		var test = window.open(null,"","width=1,height=1,status=0,location=0,toolbar=0,menubar=0,scrollbars=0,resizable=0,");
		try {
				test.close();
				Set_Cookie( 'popupsenabled', 'true', '', '/', '', '' );
//				alert("Pop-ups not blocked.");
		} catch (e) {
				alert("Pop-ups are currently blocked, please allow popups for this site\r\nas they are occasionally used for information pages.");
		}
}

// Created by: Simon Willison
// http://simon.incutio.com/archive/2004/05/26/addLoadEvent
function addLoadEvent(func) {
  var oldonload = window.onload;
  
  if (typeof window.onload != 'function') {
    window.onload = func;
  } else {
    window.onload = function() {
      if (oldonload) {
        oldonload();
      }
      func();
    }
  }
}

// ActionConfirmation.js


var formContinueAction = 1;

function formSubmitCheck(form)
{
//	alert("form check: " + form.name);
	var blockAction = (formContinueAction == 0);
	formContinueAction = 1; // reset formContinueAction
	if (blockAction)
	{
		return false;
	}
	return true;
}

function actionConfirmation(btn, form, fieldtext, actionName)
{
//	alert(actionName + " button: " + btn.name + " : " + form.name);
	formContinueAction = 0;

	var selectedOption = fieldtext;
	
	if (confirm("Are you sure you want to " + actionName + " " + selectedOption + " ?"))
	{
		formContinueAction = 1;
	}
	return false;
}


var submitted = false;

function CreditCardPaymentConfirmation(btn, form)
{
//	alert(actionName + " button: " + btn.name + " : " + form.name);
	formContinueAction = 0;

	if(submitted == true) { return false; }

	if (confirm("Click OK to continue with the credit card payment.\r\n\r\nDo not refresh the page while transaction is being processed.\r\n\r\nCredit card clearance may take up to 1 minute."))
	{
		btn.value = 'Payment in progress...';
		formContinueAction = 1;
		submitted = true;
	}
	
	return false;
}

// dropdownautocomplete.js

// JScript File

// -------------------------------------------------------------------
// autoComplete (text_input, select_input, ["text"|"value"])
//   Arguments:
//      field = text input field object
//      select = select list object containing valid values
//      filteredselect = select list object containing values that match the current input
// -------------------------------------------------------------------
function autoComplete (evt, field, select, filteredselect) {

	// clear the filtered selection
	filteredselect.options.length = 0;
	filteredselect.style.height = '0px';

	var code;
	
	if (!evt) evt = window.event;
	if (evt.keyCode) code = evt.keyCode;
	else if (evt.which) code = evt.which;

	var showall = false;	

	// down arrow or "*" entered
	if (code == 40 || field.value == "*")
	{
		showall = true;
	}

	var x = 0;
	var first = 0;
	
	var line = field.value;
	var wordList = line.split(" ");
	var selectListText = new Array(select.options.length);
	var selectListValue = new Array(select.options.length);
	
	// Copy all lines into filtered select list
	for (var i = 0; i < select.options.length; i++) 
	{
		if (select.options[i].text.length > 0)
		{
			selectListText[i] = select.options[i].text;
			selectListValue[i] = select.options[i].value;
		}
	}

	if (!showall)
	{
		// now remove lines that do not match entered text
		for (var a = 0; a < wordList.length; a++)
		{
			line = wordList[a];
			if (line.length > 0)
			{
				for (var i = 0; i < selectListText.length; i++) 
				{
					if (selectListText[i] == null) continue;
					if (selectListText[i].toUpperCase().indexOf(line.toUpperCase()) < 0) 
					{
						selectListText[i] = null;
						selectListValue[i] = null;
					}
				}
			}
		}
	}
	
	var a = 0;
	for (var i = 0; i < selectListText.length; i++) 
	{
		// now build the filtered select list so that it contains the matched items
		if (selectListText[i] != null)
		{
			filteredselect.options[a] = new Option( selectListText[i], selectListValue[i] );
			a = a + 1;
		}
	}

	i = first;

	if (filteredselect.length > 0) { select.selectedIndex = i; }
	else { select.selectedIndex = -1; }
	
	var height = filteredselect.options.length * 17;
	if (height > 150)
		height = 150;
	
	if (height < 20)
		height = 20;

	if (!showall && field.value.length == 0)
		height = 0;
		
	filteredselect.style.height = height + 'px';

	if (!showall && field.value.length == 0)
		filteredselect.options.length = 0;
}

function LTrim( value ) {
	var re = /\s*((\S+\s*)*)/;
	return value.replace(re, "$1");
}

function RTrim( value ) {
	var re = /((\s*\S+)*)\s*/;
	return value.replace(re, "$1");
}

function trim( value ) {
	return LTrim(RTrim(value));
}

// javascript_cookies.js

/*
Script Name: Javascript Cookie Script
Author: Public Domain, with some modifications
Script Source URI: http://techpatterns.com/downloads/javascript_cookies.php
Version 1.0.0
Last Update: 30 May 2004

This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  
*/

// this function gets the cookie, if it exists
function Get_Cookie( name ) {
	
	var start = document.cookie.indexOf( name + "=" );
	var len = start + name.length + 1;
	if ( ( !start ) && ( name != document.cookie.substring( 0, name.length ) ) )
	{
		return null;
	}
	if ( start == -1 ) return null;
	var end = document.cookie.indexOf( ";", len );
	if ( end == -1 ) end = document.cookie.length;
	return unescape( document.cookie.substring( len, end ) );
}

/*
only the first 2 parameters are required, the cookie name, the cookie
value. Cookie time is in milliseconds, so the below expires will make the 
number you pass in the Set_Cookie function call the number of days the cookie
lasts, if you want it to be hours or minutes, just get rid of 24 and 60.

Generally you don't need to worry about domain, path or secure for most applications
so unless you need that, leave those parameters blank in the function call.
*/
function Set_Cookie( name, value, expires, path, domain, secure ) {
	// set time, it's in milliseconds
	var today = new Date();
	today.setTime( today.getTime() );
	// if the expires variable is set, make the correct expires time, the
	// current script below will set it for x number of days, to make it
	// for hours, delete * 24, for minutes, delete * 60 * 24
	if ( expires )
	{
		expires = expires * 1000 * 60 * 60 * 24;
	}
	//alert( 'today ' + today.toGMTString() );// this is for testing purpose only
	var expires_date = new Date( today.getTime() + (expires) );
	//alert('expires ' + expires_date.toGMTString());// this is for testing purposes only

	document.cookie = name + "=" +escape( value ) +
		( ( expires ) ? ";expires=" + expires_date.toGMTString() : "" ) + //expires.toGMTString()
		( ( path ) ? ";path=" + path : "" ) + 
		( ( domain ) ? ";domain=" + domain : "" ) +
		( ( secure ) ? ";secure" : "" );
}

// this deletes the cookie when called
function Delete_Cookie( name, path, domain ) {
	if ( Get_Cookie( name ) ) document.cookie = name + "=" +
			( ( path ) ? ";path=" + path : "") +
			( ( domain ) ? ";domain=" + domain : "" ) + 
			";expires=Thu, 01-Jan-1970 00:00:01 GMT";
}


// menu.js




function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}

MM_reloadPage(true);


function MM_findObj_old(n, d) { //v4.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && document.getElementById) x=document.getElementById(n); return x;
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_showHideLayers() { //v3.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v='hide')?'hidden':v; }
    obj.visibility=v; }
}


function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}


function openbox(thisbox) {
	isbox = thisbox
		if(document.layers) {
			box = document.popupbox
			box.visibility="visible"
			document.popupbox.document.write("<img src='"+thisbox+"'>")
			document.popupbox.document.close()
			document.popupbox.left=x-3
			document.popupbox.top=y-18
		}

		if(document.all) {
			box = document.all.popupbox.style
			box.visibility="visible"
			popupbox.innerHTML="<img src='"+thisbox+"'>"
			eval(doc+"popupbox"+stl+left_pos+(x-3))
			eval(doc+"popupbox"+stl+top_pos+(y-18))
			timer=setTimeout("openbox(isbox)",50)
		}

}

function closebox(){
		clearTimeout(timer)
		box.visibility="HIDDEN"
}

function handlerMM(e){
	x = (document.layers) ? e.pageX : event.clientX
	y = (document.layers) ? e.pageY : event.clientY
}

// openwin.js
function MM_openBrWindow(theURL,winName,features)
{ //v2.0
  win = window.open(theURL,winName,features);
  win.opener = window;
  if (window.focus) {win.focus()}
  return false;
}

function MM_openHelpWindow(theUrl, theWidth, theHeight)
{
	return MM_openBrWindow(theUrl,'help','width=' + theWidth + ',height=' + theHeight + ',toobar=no,scrollbars=yes,location=no,resizable=yes');
}

function MM_openImageWindow(theUrl)
{
	return MM_openBrWindow(theUrl,'help','width=500,height=500,toobar=no,scrollbars=yes,location=no,resizeable=yes');
}

function MM_openMainWindow(theUrl, theWidth, theHeight)
{
	return MM_openBrWindow(theUrl,'main','width=' + theWidth + ',height=' + theHeight + ',toobar=yes,scrollbars=yes,location=yes,resizable=yes,dependent=yes,alwaysRaised=yes');
}


// popupmain.js

<!-- 
/*
 Pleas leave this notice.
 DHTML tip message version 1.2 copyright Essam Gamal 2003 (http://migoicons.tripod.com, migoicons@hotmail.com)
 All modifications are done in the style.js you should not modify this file.  Created on : 06/03/2003
 Script featured on and can be found at Dynamic Drive (http://www.dynamicdrive.com)
*/ 

var ua = navigator.userAgent
var ps = navigator.productSub 
var dom = (document.getElementById)? 1:0
var ie4 = (document.all&&!dom)? 1:0
var ie5 = (document.all&&dom)? 1:0
var nn4 =(navigator.appName.toLowerCase() == "netscape" && parseInt(navigator.appVersion) == 4)
var nn6 = (dom&&!ie5)? 1:0
var sNav = (nn4||nn6||ie4||ie5)? 1:0
var cssFilters = ((ua.indexOf("MSIE 5.5")>=0||ua.indexOf("MSIE 6")>=0)&&ua.indexOf("Opera")<0)? 1:0
var Style=[],Text=[],Count=0,sbw=0,move=0,hs="",mx,my,scl,sct,ww,wh,obj,sl,st,ih,iw,vl,hl,sv,evlh,evlw,tbody
var HideTip = "eval(obj+sv+hl+';'+obj+sl+'=0;'+obj+st+'=-800')"
var doc_root = ((ie5&&ua.indexOf("Opera")<0||ie4)&&document.compatMode=="CSS1Compat")? "document.documentElement":"document.body"
var PX = (nn6)? "px" :"" 

if(sNav) {
	window.onresize = ReloadTip
	document.onmousemove = MoveTip
	if(nn4) document.captureEvents(Event.MOUSEMOVE) 
}	
if(nn4||nn6) {
	mx = "e.pageX"
	my = "e.pageY"
	scl = "window.pageXOffset"
	sct = "window.pageYOffset"	
	if(nn4) {
		obj = "document.TipLayer."
		sl = "left"
		st = "top"
		ih = "clip.height"
		iw = "clip.width"
		vl = "'show'"
		hl = "'hide'"
		sv = "visibility="
	}
	else obj = "document.getElementById('TipLayer')."
} 
if(ie4||ie5) {
	obj = "TipLayer."
	mx = "event.x"
	my = "event.y"
	scl = "eval(doc_root).scrollLeft"
	sct = "eval(doc_root).scrollTop"
	if(ie5) {
		mx = mx+"+"+scl 
		my = my+"+"+sct
	}
}
if(ie4||dom){
	sl = "style.left"
	st = "style.top"
	ih = "offsetHeight"
	iw = "offsetWidth"
	vl = "'visible'"
	hl = "'hidden'"
	sv = "style.visibility="
}
if(ie4||ie5||ps>=20020823) {
	ww = "eval(doc_root).clientWidth"
	wh = "eval(doc_root).clientHeight"
}	 
else { 
	ww = "window.innerWidth"
	wh = "window.innerHeight"
	evlh = eval(wh)
	evlw = eval(ww)
	sbw=15
}	

function applyCssFilter(){
	if(cssFilters&&FiltersEnabled) { 
		var dx = " progid:DXImageTransform.Microsoft."
		TipLayer.style.filter = "revealTrans()"+dx+"Fade(Overlap=1.00 enabled=0)"+dx+"Inset(enabled=0)"+dx+"Iris(irisstyle=PLUS,motion=in enabled=0)"+dx+"Iris(irisstyle=PLUS,motion=out enabled=0)"+dx+"Iris(irisstyle=DIAMOND,motion=in enabled=0)"+dx+"Iris(irisstyle=DIAMOND,motion=out enabled=0)"+dx+"Iris(irisstyle=CROSS,motion=in enabled=0)"+dx+"Iris(irisstyle=CROSS,motion=out enabled=0)"+dx+"Iris(irisstyle=STAR,motion=in enabled=0)"+dx+"Iris(irisstyle=STAR,motion=out enabled=0)"+dx+"RadialWipe(wipestyle=CLOCK enabled=0)"+dx+"RadialWipe(wipestyle=WEDGE enabled=0)"+dx+"RadialWipe(wipestyle=RADIAL enabled=0)"+dx+"Pixelate(MaxSquare=35,enabled=0)"+dx+"Slide(slidestyle=HIDE,Bands=25 enabled=0)"+dx+"Slide(slidestyle=PUSH,Bands=25 enabled=0)"+dx+"Slide(slidestyle=SWAP,Bands=25 enabled=0)"+dx+"Spiral(GridSizeX=16,GridSizeY=16 enabled=0)"+dx+"Stretch(stretchstyle=HIDE enabled=0)"+dx+"Stretch(stretchstyle=PUSH enabled=0)"+dx+"Stretch(stretchstyle=SPIN enabled=0)"+dx+"Wheel(spokes=16 enabled=0)"+dx+"GradientWipe(GradientSize=1.00,wipestyle=0,motion=forward enabled=0)"+dx+"GradientWipe(GradientSize=1.00,wipestyle=0,motion=reverse enabled=0)"+dx+"GradientWipe(GradientSize=1.00,wipestyle=1,motion=forward enabled=0)"+dx+"GradientWipe(GradientSize=1.00,wipestyle=1,motion=reverse enabled=0)"+dx+"Zigzag(GridSizeX=8,GridSizeY=8 enabled=0)"+dx+"Alpha(enabled=0)"+dx+"Dropshadow(OffX=3,OffY=3,Positive=true,enabled=0)"+dx+"Shadow(strength=3,direction=135,enabled=0)"
	}
}

function arrayPopup(t,s) {
  if(sNav) {
  	if(t.length<2||s.length<25) {
		var ErrorNotice = "DHTML TIP MESSAGE VERSION 1.2 ERROR NOTICE.\n"
		if(t.length<2&&s.length<25) alert(ErrorNotice+"It looks like you removed an entry or more from the Style Array and Text Array of this tip.\nTheir should be 25 entries in every Style Array even though empty and 2 in every Text Array. You defined only "+s.length+" entries in the Style Array and "+t.length+" entry in the Text Array. This tip won't be viewed to avoid errors")
		else if(t.length<2) alert(ErrorNotice+"It looks like you removed an entry or more from the Text Array of this tip.\nTheir should be 2 entries in every Text Array. You defined only "+t.length+" entry. This tip won't be viewed to avoid errors.")
		else if(s.length<25) alert(ErrorNotice+"It looks like you removed an entry or more from the Style Array of this tip.\nTheir should be 25 entries in every Style Array even though empty. You defined only "+s.length+" entries. This tip won't be viewed to avoid errors.")
 	}
  	else {
		var ab = "" ;var ap = ""
		var titCol = (s[0])? "COLOR='"+s[0]+"'" : ""
		var txtCol = (s[1])? "COLOR='"+s[1]+"'" : ""
		var titBgCol = (s[2])? "BGCOLOR='"+s[2]+"'" : ""
		var txtBgCol = (s[3])? "BGCOLOR='"+s[3]+"'" : ""
		var titBgImg = (s[4])? "BACKGROUND='"+s[4]+"'" : ""	
		var txtBgImg = (s[5])? "BACKGROUND='"+s[5]+"'" : ""
		var titTxtAli = (s[6] && s[6].toLowerCase()!="left")? "ALIGN='"+s[6]+"'" : ""
		var txtTxtAli = (s[7] && s[7].toLowerCase()!="left")? "ALIGN='"+s[7]+"'" : ""   
		var add_height = (s[15])? "HEIGHT='"+s[15]+"'" : ""
		if(!s[8])  s[8] = "Verdana,Arial,Helvetica"
		if(!s[9])  s[9] = "Verdana,Arial,Helvetica"					
		if(!s[12]) s[12] = 1
		if(!s[13]) s[13] = 1
		if(!s[14]) s[14] = 200
		if(!s[16]) s[16] = 0
		if(!s[17]) s[17] = 0
		if(!s[18]) s[18] = 10
		if(!s[19]) s[19] = 10
		hs = s[11].toLowerCase() 
		if(ps==20001108){
		if(s[2]) ab="STYLE='border:"+s[16]+"px solid"+" "+s[2]+"'"
		ap="STYLE='padding:"+s[17]+"px "+s[17]+"px "+s[17]+"px "+s[17]+"px'"}
		var closeLink=(hs=="sticky")? "<TD ALIGN='right'><FONT SIZE='"+s[12]+"' FACE='"+s[8]+"'><A HREF='javascript:void(0)' ONCLICK='stickyhide()' STYLE='text-decoration:none;color:"+s[0]+"'><B>Close</B></A></FONT></TD>":""
		var title=(t[0]||hs=="sticky")? "<TABLE WIDTH='100%' BORDER='0' CELLPADDING='0' CELLSPACING='0'><TR><TD "+titTxtAli+"><FONT SIZE='"+s[12]+"' FACE='"+s[8]+"' "+titCol+"><B>"+t[0]+"</B></FONT></TD>"+closeLink+"</TR></TABLE>" : ""
		var txt="<TABLE "+titBgImg+" "+ab+" WIDTH='"+s[14]+"' BORDER='0' CELLPADDING='"+s[16]+"' CELLSPACING='0' "+titBgCol+" ><TR><TD>"+title+"<TABLE WIDTH='100%' "+add_height+" BORDER='0' CELLPADDING='"+s[17]+"' CELLSPACING='0' "+txtBgCol+" "+txtBgImg+"><TR><TD "+txtTxtAli+" "+ap+" VALIGN='top'><FONT SIZE='"+s[13]+"' FACE='"+s[9]+"' "+txtCol +">"+t[1]+"</FONT></TD></TR></TABLE></TD></TR></TABLE>"
		if(nn4) {
			with(eval(obj+"document")) {
				open()
				write(txt)
				close()
			}
		}
		else eval(obj+"innerHTML=txt")
		tbody = {
			Pos:s[10].toLowerCase(), 
			Xpos:s[18],
			Ypos:s[19], 
			Transition:s[20],
			Duration:s[21], 
			Alpha:s[22],
			ShadowType:s[23].toLowerCase(),
			ShadowColor:s[24],
			Width:parseInt(eval(obj+iw)+3+sbw)
		}
		if(ie4) { 
			TipLayer.style.width = s[14]
	 		tbody.Width = s[14]
		}
		Count=0	
		move=1
 	 }
  }
}

function arrayPopup2(c,t,s) {
  if(sNav) {
  	if(s == null || s.length<25) {
  	    var theLength = 0
  	    if (s != null)
  	        theLength = s.length;
  	        
		var ErrorNotice = "DHTML TIP MESSAGE VERSION 1.2 ERROR NOTICE.\n"
			alert(ErrorNotice+"It looks like you removed an entry or more from the Style Array of this tip.\nTheir should be 25 entries in every Style Array even though empty. You defined only "+theLength+" entries. This tip won't be viewed to avoid errors.")
 	}
  	else {
		var ab = "" ;var ap = ""
		var titCol = (s[0])? "COLOR='"+s[0]+"'" : ""
		var txtCol = (s[1])? "COLOR='"+s[1]+"'" : ""
		var titBgCol = (s[2])? "BGCOLOR='"+s[2]+"'" : ""
		var txtBgCol = (s[3])? "BGCOLOR='"+s[3]+"'" : ""
		var titBgImg = (s[4])? "BACKGROUND='"+s[4]+"'" : ""	
		var txtBgImg = (s[5])? "BACKGROUND='"+s[5]+"'" : ""
		var titTxtAli = (s[6] && s[6].toLowerCase()!="left")? "ALIGN='"+s[6]+"'" : ""
		var txtTxtAli = (s[7] && s[7].toLowerCase()!="left")? "ALIGN='"+s[7]+"'" : ""   
		var add_height = (s[15])? "HEIGHT='"+s[15]+"'" : ""
		if(!s[8])  s[8] = "Verdana,Arial,Helvetica"
		if(!s[9])  s[9] = "Verdana,Arial,Helvetica"					
		if(!s[12]) s[12] = 1
		if(!s[13]) s[13] = 1
		if(!s[14]) s[14] = 200
		if(!s[16]) s[16] = 0
		if(!s[17]) s[17] = 0
		if(!s[18]) s[18] = 10
		if(!s[19]) s[19] = 10
		hs = s[11].toLowerCase() 
		if(ps==20001108){
		if(s[2]) ab="STYLE='border:"+s[16]+"px solid"+" "+s[2]+"'"
		ap="STYLE='padding:"+s[17]+"px "+s[17]+"px "+s[17]+"px "+s[17]+"px'"}
		var closeLink=(hs=="sticky")? "<TD ALIGN='right'><FONT SIZE='"+s[12]+"' FACE='"+s[8]+"'><A HREF='javascript:void(0)' ONCLICK='stickyhide()' STYLE='text-decoration:none;color:"+s[0]+"'><B>Close</B></A></FONT></TD>":""
		var title=(c||hs=="sticky")? "<TABLE WIDTH='100%' BORDER='0' CELLPADDING='0' CELLSPACING='0'><TR><TD "+titTxtAli+"><FONT SIZE='"+s[12]+"' FACE='"+s[8]+"' "+titCol+"><B>"+c+"</B></FONT></TD>"+closeLink+"</TR></TABLE>" : ""
		var txt="<TABLE "+titBgImg+" "+ab+" WIDTH='"+s[14]+"' BORDER='0' CELLPADDING='"+s[16]+"' CELLSPACING='0' "+titBgCol+" ><TR><TD>"+title+"<TABLE WIDTH='100%' "+add_height+" BORDER='0' CELLPADDING='"+s[17]+"' CELLSPACING='0' "+txtBgCol+" "+txtBgImg+"><TR><TD "+txtTxtAli+" "+ap+" VALIGN='top'><FONT SIZE='"+s[13]+"' FACE='"+s[9]+"' "+txtCol +">"+t+"</FONT></TD></TR></TABLE></TD></TR></TABLE>"
		if(nn4) {
			with(eval(obj+"document")) {
				open()
				write(txt)
				close()
			}
		}
		else eval(obj+"innerHTML=txt")
		tbody = {
			Pos:s[10].toLowerCase(), 
			Xpos:s[18],
			Ypos:s[19], 
			Transition:s[20],
			Duration:s[21], 
			Alpha:s[22],
			ShadowType:s[23].toLowerCase(),
			ShadowColor:s[24],
			Width:parseInt(eval(obj+iw)+3+sbw)
		}
		if(ie4) { 
			TipLayer.style.width = s[14]
	 		tbody.Width = s[14]
		}
		Count=0	
		move=1
 	 }
  }
}

function MoveTip(e) {
	if(move) {
		var X,Y,MouseX = eval(mx),MouseY = eval(my); tbody.Height = parseInt(eval(obj+ih)+3)
		tbody.wiw = parseInt(eval(ww+"+"+scl)); tbody.wih = parseInt(eval(wh+"+"+sct))
		switch(tbody.Pos) {
			case "left" : X=MouseX-tbody.Width-tbody.Xpos; Y=MouseY+tbody.Ypos; break
			case "center": X=MouseX-(tbody.Width/2); Y=MouseY+tbody.Ypos; break
			case "float": X=tbody.Xpos+eval(scl); Y=tbody.Ypos+eval(sct); break	
			case "fixed": X=tbody.Xpos; Y=tbody.Ypos; break		
			default: X=MouseX+tbody.Xpos; Y=MouseY+tbody.Ypos
		}

		if(tbody.wiw<tbody.Width+X) X = tbody.wiw-tbody.Width
		if(tbody.wih<tbody.Height+Y+sbw) {
			if(tbody.Pos=="float"||tbody.Pos=="fixed") Y = tbody.wih-tbody.Height-sbw
			else Y = MouseY-tbody.Height
		}
		if(X<0) X=0 
		eval(obj+sl+"=X+PX;"+obj+st+"=Y+PX")
		ViewTip()
	}
}

function ViewTip() {
  	Count++;
	if(Count == 1) {
		if(cssFilters&&FiltersEnabled) {	
			for(Index=28; Index<31; Index++) { TipLayer.filters[Index].enabled = 0 }
			for(s=0; s<28; s++) { if(TipLayer.filters[s].status == 2) TipLayer.filters[s].stop() }
			if(tbody.Transition == 51) tbody.Transition = parseInt(Math.random()*50)
			var applyTrans = (tbody.Transition>-1&&tbody.Transition<24&&tbody.Duration>0)? 1:0
			var advFilters = (tbody.Transition>23&&tbody.Transition<51&&tbody.Duration>0)? 1:0
			var which = (applyTrans)?0:(advFilters)? tbody.Transition-23:0 
			if(tbody.Alpha>0&&tbody.Alpha<100) {
	  			TipLayer.filters[28].enabled = 1
	  			TipLayer.filters[28].opacity = tbody.Alpha
			}
			if(tbody.ShadowColor&&tbody.ShadowType == "simple") {
	  			TipLayer.filters[29].enabled = 1
	  			TipLayer.filters[29].color = tbody.ShadowColor
			}
			else if(tbody.ShadowColor&&tbody.ShadowType == "complex") {
	  			TipLayer.filters[30].enabled = 1
	  			TipLayer.filters[30].color = tbody.ShadowColor
			}
			if(applyTrans||advFilters) {
				eval(obj+sv+hl)
	  			if(applyTrans) TipLayer.filters[0].transition = tbody.Transition
	  			TipLayer.filters[which].duration = tbody.Duration 
	  			TipLayer.filters[which].apply()
			}
		}
 		eval(obj+sv+vl)
		if(cssFilters&&FiltersEnabled&&(applyTrans||advFilters)) TipLayer.filters[which].play()
		if(hs == "sticky") move=0
  	}
}

function stickyhide() {
	eval(HideTip)
}

function ReloadTip() {
	 if(nn4&&(evlw!=eval(ww)||evlh!=eval(wh))) location.reload()
	 else if(hs == "sticky") eval(HideTip)
}

function closePopup() {
	if(sNav) {
		if(hs!="keep") {
			move=0; 
			if(hs!="sticky") eval(HideTip)
		}	
	} 
}


//-->

// popupwindows.js




function NewWindow(mypage, myname, w, h, scroll) {
var winl = (screen.width - w) / 2;
var wint = (screen.height - h) / 2;
winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars='+scroll+',resizable'
win = window.open(mypage, myname, winprops)
if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); }
}

function popup_local(url) {

	var obj_calwindow = window.open(
		url,
		'Info', 'width=790,height=600'+
		',status=yes,resizable=yes,top=400,left=400,toolbar=yes,dependent=yes,alwaysRaised=yes,location=yes,scrollbars=yes'
	);
	
	obj_calwindow.opener = window;
	obj_calwindow.focus();
}

function popup_local2(url, w, h) {
	var obj_calwindow = window.open(
		url,
		'Info', 'width=' + w + ',height=' + h +
		',status=no,resizable=yes,top=400,left=400,dependent=yes,alwaysRaised=yes,location=no,scrollbars=yes'
	);
	
	obj_calwindow.opener = window;
	obj_calwindow.focus();
}


function popup_info(url) {
	var obj_calwindow = window.open(
		helpSiteUrl() + url + ThemeIndicator(),
		'Info', 'width=790,height=600'+
		',status=yes,resizable=yes,top=400,left=400,toolbar=yes,dependent=yes,alwaysRaised=yes,location=yes,scrollbars=yes'
	);
	
	obj_calwindow.opener = window;
	obj_calwindow.focus();
}

function popup_help(url) {
	var obj_calwindow = window.open(
		helpSiteUrl() + url + ThemeIndicator(),
		'Help', 'width=650,height=510'+
		',status=no,resizable=yes,top=400,left=400,dependent=yes,alwaysRaised=yes,location=no,scrollbars=yes'
	);
	
	obj_calwindow.opener = window;
	obj_calwindow.focus();
}

function popup_help2(url, w, h) {
	var obj_calwindow = window.open(
		helpSiteUrl() + url + ThemeIndicator() ,
		'Help', 'width=' + w + ',height=' + h +
		',status=no,resizable=yes,top=400,left=400,dependent=yes,alwaysRaised=yes,location=no,scrollbars=yes'
	);
	
	obj_calwindow.opener = window;
	obj_calwindow.focus();
}


function popup_info_search(url, searchText) {
	url = url.replace("{0}", searchText );
	popup_info(url);
}

function popup_corporate(url) {
	if (opener)
	{
		opener.document.location = mainSiteUrl() + url + ThemeIndicator();
		opener.focus();
	}
	else
	{
		document.location = mainSiteUrl() + url + ThemeIndicator();
	}
}

function popup_fixed(url,h,w) {
	var obj_calwindow = window.open(
		url,
		'PopupFixed', 'width='+w+',height=' + h + 
		',status=yes,resizable=yes,top=400,left=400,dependent=yes,alwaysRaised=yes,toolbar=no,location=no,scrollbars=no'
	);
	
	obj_calwindow.opener = window;
	obj_calwindow.focus();
}

function popup(url) {
	var obj_calwindow = window.open(
		url,
		'Popup', 'width=790,height=600'+
		',status=yes,resizable=yes,top=400,left=400,toolbar=yes,dependent=yes,alwaysRaised=yes,location=yes,scrollbars=yes'
	);
	
	obj_calwindow.opener = window;
	obj_calwindow.focus();
}


// toggle_class.js

// <![CDATA[

var getById = (typeof document.getElementById != "undefined");		

function toggleClassName(obj, class1, class2){
    obj= getRef(obj);
    
        // obj.isClass1 will be false the first time.
    if(!obj.isClass1){
        obj.className= class1;
        obj.isClass1= true;
    }
    else{
        obj.className= class2;
        obj.isClass1= false;
    }
    // repaintFix(obj.parentNode);
}

function getRef(obj){
    if(getById)
    	return(typeof obj == "string") ? document.getElementById(obj) : obj;
}

function repaintFix(obj){ 
	
	if("undefined" == typeof document.body
	  || "undefined" == typeof document.body.style) return;
	
	if(obj == null)
		obj == document.body;
	else obj = getRef(obj);
	
	document.body.style.visibility = "hidden";
	document.body.style.visibility = "visible";
}

// ]]>


// toggle_display.js



var getById = (typeof document.getElementById != "undefined");		

function toggleDisplay(obj,display1,display2){

	if(!getById) return;
	
	obj = getRef(obj);

	if(obj == null) return;
	if(display1 == null) return;
	
	if(obj.style.display == display1)
		obj.style.display = display2;
	else
		obj.style.display = display1;
	
	repaintFix();
}

function setDisplay(obj,display1){

	if(!getById) return;
	
	obj = getRef(obj);
	
	if (obj == null) return;
	obj.style.display = display1;
	
	repaintFix(obj);
}


function getRef(obj){
	if(getById)
		return(typeof obj == "string") ? document.getElementById(obj) : obj;
}

function repaintFix(obj){ 
	
	if("undefined" == typeof document.body
	  || "undefined" == typeof document.body.style) return;
	
	if(obj == null)
		obj == document.body;
	else obj = getRef(obj);
	
//	document.body.style.visibility = "hidden";
	document.body.style.visibility = "visible";
}

// toggle_style.js

function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);


function MM_findObj(n, d) { //v4.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && document.getElementById) x=document.getElementById(n); return x;
}

function MM_showHideLayers() { //v3.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v='hide')?'hidden':v; }
    obj.visibility=v; }
}


function MM_blockNoneLayers() { //v3.0
  var i,p,m,obj,args=MM_blockNoneLayers.arguments;	 
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { m=args[i+2];
    if (obj.style) { obj=obj.style; m=(m=='block')?'block':(m='none')?'none':m; }
    obj.display=m; }
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}


