function OpenFlash(flashfile, width, height){document.write("<table cellpadding='0' cellspacing='0' border='0'><tr><td><object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,47,0' width='"+width+"' height='"+height+"'><param name='movie' value='"+ flashfile +"' /><param name='quality' value='high' /><param name='bgcolor' value='#000000'/><param name='loop' value='false' /><embed src='"+flashfile+"' loop='false' quality='high' bgcolor='#000000' width='"+width+"' height='"+height+"' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer'></embed></object></td></tr></table>"); }
function OpenSurroundVideo(file, width, height, filepath){if (width == null || width == "")width="320"; if (height==null || height =="")height="240";  myvideo = "<object classid='clsid:928626A3-6B98-11CF-90B4-00AA00A4011F' type='application/x-oleobject' id='Surround1'" + " codebase='" + filepath+ "apps/svj/MSSurVid.cab#Version=1,2,0,20' width='" +width + "' height='" + height + "'>" + "<param name='SurroundRect' value='0,0,320,240' /><param name='Image' value='"+file+"'></param></object>";  document.write(myvideo); }
function OpenWindowsMedia(file){document.write("<embed type='application/x-mplayer2' name='MediaPlayer' autostart='true'  src='" + file + "'></embed>"); }
function OpenQuickTime(file, width, height){document.write("<embed PLUGINSPAGE='http:/" + "/www.apple.com/quicktime/download/' src='"+ file +"' width='"+width+"' height='"+height+"'></embed>"); }
//**********************************************Above are functions for activex components
function OpenPopup(div){var s = div.innerHTML;  var win = window.open ("","_SlatePopup","directories=no,height=300,width=450,menubar=no,resizeable=no,scrollbars=no,status=no,toolbar=no");  var base = win.document.createElement("base");  base.target = "_new";  win.document.createStyleSheet("/css/shared.css");  win.document.body.topMargin = 0;  win.document.body.leftMargin = 0;  win.document.body.innerHTML = div.innerHTML;  var head = win.document.getElementsByTagName("head")(0);  base = head.insertBefore(base);  win.focus(); return; }/* Functions for Numeric Navigation scrolling */
var FirstChildNumNav;  var LastChildNumNav;  var MaxView;  
function InitNumericNav(){var children = NumericNavTable.children; var NumberedChildren = children.length-2; var child; MaxView = 9; var thisEntry = thisentry(0); var EntryId = Number(thisEntry.innerText); if (EntryId <= MaxView){EntryId = 1; }if (EntryId > 1){leftArrow.style.visibility = 'visible'; leftArrowBottom.style.visibility = 'visible'; }if (NumberedChildren > MaxView){if (NumberedChildren - EntryId < MaxView){EntryId = NumberedChildren - MaxView + 1; rightArrow.style.visibility = 'hidden'; rightArrowBottom.style.visibility = 'hidden'; }else{rightArrow.style.visibility = 'visible'; rightArrowBottom.style.visibility = 'visible'; }}for (i=1; (EntryId<(NumberedChildren+1) && i<=MaxView); i++){child = children(EntryId); childBottom = NumericNavTableBottom.children(EntryId); child.style.display = ''; childBottom.style.display = ''; if (i==1)FirstChildNumNav = child; EntryId++; }LastChildNumNav = child; return; }
function RightArrowNumNav(){leftArrow.style.visibility = 'visible'; leftArrowBottom.style.visibility = 'visible'; if (FirstChildNumNav.nextSibling != null){if (FirstChildNumNav.nextSibling.id != 'rightArrow'){FirstChildNumNav.style.display = 'none'; var id = FirstChildNumNav.id; document.all(id)(1).style.display = 'none'; FirstChildNumNav = FirstChildNumNav.nextSibling; }}if (LastChildNumNav.nextSibling != null){if (LastChildNumNav.nextSibling.id != 'rightArrow'){LastChildNumNav = LastChildNumNav.nextSibling; var id = LastChildNumNav.id; document.all(id)(1).style.display = ''; LastChildNumNav.style.display = ''; }}else return; if (LastChildNumNav.nextSibling.id == 'rightArrow'){rightArrow.style.visibility = 'hidden'; rightArrowBottom.style.visibility = 'hidden'; }return; }
function LeftArrowNumNav(){rightArrow.style.visibility = 'visible'; rightArrowBottom.style.visibility = 'visible'; if (LastChildNumNav.previousSibling != null){if (LastChildNumNav.previousSibling.id != 'leftArrow'){LastChildNumNav.style.display = 'none'; var id = LastChildNumNav.id; document.all(id)(1).style.display = 'none'; LastChildNumNav = LastChildNumNav.previousSibling; }}if (FirstChildNumNav.previousSibling != null){if (FirstChildNumNav.previousSibling.id != 'leftArrow'){FirstChildNumNav = FirstChildNumNav.previousSibling; var id = FirstChildNumNav.id; document.all(id)(1).style.display = ''; FirstChildNumNav.style.display = ''; }}else return; if (FirstChildNumNav.previousSibling.id == 'leftArrow'){leftArrow.style.visibility = 'hidden'; leftArrowBottom.style.visibility = 'hidden'; }return; }/* END Functions for Numeric Navigation scrolling */
function toolAction(action, id, tocid) {var title; var windowParam; if (id==''){var url = window.location.href; var idPos = url.indexOf("id="); if (idPos != -1){var ampPos = url.indexOf("&"); if (ampPos != -1)id = url.substring(idPos+3,ampPos); else id = url.substr(idPos+3); }}var URLParam = "?action="+action+"&id="+id; if (id=='toc')URLParam += "&tocid="+tocid; switch (action) {case 'print':title='Print'; windowParam = 'toolbar=no,location=no,directories=no,menubar=no,status=no,resizable=yes,scrollbars=yes,width=640,height=480'; window.open("/toolbar.aspx"+URLParam, title, windowParam); break; case 'email':title='Email'; windowParam = 'toolbar=no,location=no,directories=no,menubar=no,status=no,resizable=yes,scrollbars=no,width=490,height=470'; window.open("/toolbar.aspx"+URLParam, title, windowParam); break; }}/*End Toolbar Navigation *//* MSN Shell functions */
function showHideSidebar(){if(document.all)var iWidth = document.body.clientWidth; document.all.sidebarshell.style.display = (iWidth > 913 ? '' : 'none'); document.all.sidebarshell.style.height = document.body.scrollHeight - 1; }/* End MSN Shell functions *//* This function will resize the iframe so that there are no scrollbars */
function LoadIframe(el){var n = el.name; var h = document.frames(n).document.body.scrollHeight; el.height = h; window.focus(); }var MenuDelay = 50; var timerShowMenu; var timerHideMenu; var ActiveMenu = null; var ActiveEl = null; 
function ImgOn(el, i, pageid) {if (menudropdowns.innerText == '') return; if (el.className != "m_active")el.className = "m_over"; if (ActiveEl != null)if (ActiveEl.className != "m_active")ActiveEl.className = "m_off"; if (ActiveMenu != null)ShowMenu(pageid, i); else timerShowMenu = window.setTimeout("ShowMenu(" + pageid + ", " + i + ")", MenuDelay); ActiveEl = el; CancelCloseMenuTimer(); }
function ImgOff(el, i) {if (menudropdowns.innerText == '') return; if (ActiveEl == null){ if (el.className != "m_active");{	el.className = "m_off";	}}if (timerShowMenu) window.clearTimeout(timerShowMenu); SetCloseMenuTimer();}
function SetCloseMenuTimer() {CancelCloseMenuTimer(); timerHideMenu = window.setTimeout("HideMenu()", MenuDelay); }
function CancelCloseMenuTimer() { if (timerHideMenu)window.clearTimeout(timerHideMenu); }// cancel menu deactivation
function ShowMenu(pageid, i) {HideMenu(); hideElement(); var m = new Menu(pageid); m.ParentMenu = null; var parentTD = document.all("menuTD" + i); var t = 220; if (typeof i != "undefined")t = parentTD.offsetTop - 1; var l = cxmenu.offsetLeft + cxmenu.offsetWidth; m.Show(t,l); }
function ShowSubMenu(pageid, el) {if (ActiveMenu.ParentMenu != null)ActiveMenu.Hide(); if (pageid != '0') ActiveMenu.ShowMenu(pageid, el); }// if pageid == '0', there is no submenu; 
function HideMenu() {if (ActiveMenu != null){ActiveMenu.Hide(); if (ActiveMenu != null)HideMenu();  if (ActiveEl != null){if (ActiveEl.className != "m_active")ActiveEl.className = "m_off"; ActiveEl = null; }}showElement(); }// call it recursively to Hide any other open menus in the hierarchy
function Menu(id) {this.id = id; this.div = document.all("divCM_" + id); this.Hide = _Hide; this.Show = _Show; this.ShowMenu = _ShowMenu; this.ChildMenu = null; this.ParentMenu = null; return (this); 
function _Hide() {this.div.style.visibility = "hidden"; ActiveMenu = this.ParentMenu; if (ActiveMenu!=null)SetCloseMenuTimer(); if ((document.all.sidebar) && (IsLessThanIE55())){document.all.sidebar.style.visibility = 'visible'; }}
function _Show(t,l) {if (this.ChildMenu != null) {this.ChildMenu.Hide(); this.ChildMenu = null; }var clientHeight = document.body.clientHeight; if ((t + this.div.offsetHeight) > clientHeight)t = clientHeight - this.div.offsetHeight; this.div.style.top = t; this.div.style.left = l; this.div.style.visibility = "visible"; this.div.onmouseover = CancelCloseMenuTimer; this.div.onmouseout = SetCloseMenuTimer; ActiveMenu = this; }
function _ShowMenu(pageid, el) {if (ActiveMenu.id != pageid){this.ChildMenu = new Menu(pageid); this.ChildMenu.ParentMenu = this; var t = el.offsetTop - 1; var clientHeight = document.body.clientHeight; var menuBottom = this.div.offsetTop + t + this.ChildMenu.div.offsetHeight; if (menuBottom > clientHeight){t = el.offsetTop - (menuBottom - clientHeight); }var l = this.div.offsetWidth; this.ChildMenu.Show(t,l); if ((document.all.sidebar) && (IsLessThanIE55())){document.all.sidebar.style.visibility = 'hidden'; }}}}
function g(l) {HideMenu(); window.location.href = l; }
function h(l) {HideMenu(); NewWindow(l+'&amp; openerurl='+escape(location.href),'01','750','550','no'); }
function HighlightView(id){var ViewId = AV[id]; if (ViewId != null){ViewId = ViewId - 1; var el = cxmenu.all("menuF" + (ViewId + 1).toString()); el.className = "m_active"; }return; }
function hideElement() { for (i = 0;  i < document.all.tags('SELECT').length;  i++) { obj = document.all.tags('SELECT')[i];  if (! obj || ! obj.offsetParent) continue;  obj.style.visibility = "hidden"; }	for (i = 0;  i < document.all.tags('OBJECT').length;  i++)	{	obj = document.all.tags('OBJECT')[i];  	if (! obj || ! obj.offsetParent) continue;  if (obj.parentElement.id != "adnohide"  && obj.parentElement.id != "sky") {	obj.style.visibility = "hidden"; } } for (i = 0;  i < document.all.tags('APPLET').length;  i++) { obj = document.all.tags('APPLET')[i];  if (! obj || ! obj.offsetParent) continue;  obj.style.visibility = "hidden"; }	for (i = 0;  i < document.all.tags('IFRAME').length;  i++) { obj = document.all.tags('IFRAME')[i];  if (! obj || ! obj.offsetParent) continue; 	if (obj.parentElement.id != "adnohide" && obj.parentElement.id != "sky") { obj.style.visibility = "hidden";	} }}
function showElement() {for (i = 0;  i < document.all.tags('SELECT').length;  i++){obj = document.all.tags('SELECT')[i];  if (! obj || ! obj.offsetParent) continue;  obj.style.visibility = ""; }for (i = 0;  i < document.all.tags('OBJECT').length;  i++){obj = document.all.tags('OBJECT')[i];  if (! obj || ! obj.offsetParent) continue;  obj.style.visibility = ""; }for (i = 0;  i < document.all.tags('APPLET').length;  i++){obj = document.all.tags('APPLET')[i];  if (! obj || ! obj.offsetParent) continue;  obj.style.visibility = ""; }for (i = 0;  i < document.all.tags('IFRAME').length;  i++){obj = document.all.tags('IFRAME')[i];  if (! obj || ! obj.offsetParent) continue;  obj.style.visibility = ""; }}
function IsLessThanIE55(){var version = window.navigator.appVersion; var pos = version.indexOf("MSIE"); if (pos != -1){var numberVersion = Number(version.substr(pos+5,3)); if (numberVersion < 5.5)return true; else return false; }else return false; }


function MenuInit()
{
	var t = menudropdowns.all.tags("table");
	for(var i = 0; i < t.length; i++)// for each table
	{
		for(var j = 0; j < t(i).rows.length; j++)//for each row
		{
			t(i).rows(j).onmouseout = mOff;
			t(i).rows(j).onmouseover = mOver;
		}
	}
}

function mOver()
{
	if(this.paid != "1")
	{
		if(this.id != -1)//don't change color or show submenu's
		{
			this.className = 'ddtrOver';
			if(this.id != -2)//don't try and show submenu's
				ShowSubMenu(this.id, this);
		}
	}
}

function mOff()
{	
	if(this.paid != "1")
	{
		if(this.id != -1)
			this.className = 'ddtr';
	}
}