// JavaScript Document

var da = (document.all) ? 1 : 0;
var pr = (window.print) ? 1 : 0;
var mac = (navigator.userAgent.indexOf("Mac") != -1); 

function printPage() {
  if (pr) // NS4, IE5
    window.print()
  else if (da && !mac) // IE4 (Windows)
    DoPrint()
  else // other browsers
    alert("Sorry, your browser doesn't support this feature. Please print from the buttons or menu above.");
  return false;
}

if (da && !pr && !mac) with (document) {
  writeln('<OBJECT ID="WB" WIDTH="0" HEIGHT="0" CLASSID="clsid:8856F961-340A-11D0-A96B-00C04FD705A2"></OBJECT>');
  writeln('<' + 'SCRIPT LANGUAGE="VBScript">');
  writeln('Sub window_onunload');
  writeln('  On Error Resume Next');
  writeln('  Set WB = nothing');
  writeln('End Sub');
  writeln('Sub DoPrint');
  writeln('  OLECMDID_PRINT = 6');
  writeln('  OLECMDEXECOPT_DONTPROMPTUSER = 2');
  writeln('  OLECMDEXECOPT_PROMPTUSER = 1');
  writeln('  On Error Resume Next');
  writeln('  WB.ExecWB OLECMDID_PRINT, OLECMDEXECOPT_DONTPROMPTUSER');
  writeln('End Sub');
  writeln('<' + '/SCRIPT>');
}

function ValidateForm(form)
{
  if (form.User_name.value == "")
  { alert("Please include your name on the form"); form.User_name.focus(); return; }

  if (form.Telephone.value == "")
  { alert("Please include your telephone number on the form"); form.Telephone.focus(); return; }

  if (form.User_email.value == "")
  { alert("Please include your email address on the form"); form.User_email.focus(); return; }

  if (form.User_email.value.indexOf('@', 0) == -1 ||
      form.User_email.value.indexOf('.', 0) == -1)
  { alert("Please enter a valid email address on the form"); form.User_email.focus(); return; }

	form.submit();
}
//
// This is the netscrape reload code that DW uses...got it out of that mess
//
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 hideBox(img)	{
		if (img == 1)
		  { document.pic1.width=0;
		  	document.pic1.height=0;
			return; }
		if (img == 2)
		  { document.pic2.width=0;
		  	document.pic2.height=0;
			return; }
		if (img == 3)
		  { document.pic3.width=0;
		  	document.pic3.height=0;
			return; }
		if (img == 4)
		  { document.pic4.width=0;
		  	document.pic4.height=0;
			return; }
		if (img == 5)
		  { document.pic5.width=0;
		  	document.pic5.height=0;
			return; }
		if (img == 6)
		  { document.pic6.width=0;
		  	document.pic6.height=0;
			return; }
		if (img == 7)
		  { document.pic7.width=0;
		  	document.pic7.height=0;
			return; }
		if (img == 8)
		  { document.pic8.width=0;
		  	document.pic8.height=0;
			return; }
		if (img == 9)
		  { document.pic9.width=0;
		  	document.pic9.height=0;
			return; }
		if (img == 99)
		  { document.bigPicture.width=0;
		  	document.bigPicture.height=0;
			return; }
		}
		
var i_strength=0
var max_strength=6
var shadowcolor="red"
var timer
var speed=50
var thisobj

function stopglow(thisdiv){
    if (document.all) {
        clearTimeout(timer)
	    thisobj=thisdiv
        thisobj.style.filter=" "
    }
}


function startglow(thisdiv){
    if (document.all) {
        clearTimeout(timer)
	    thisobj=thisdiv
        morefilter()
    }
}

function morefilter(){
    if (i_strength <=max_strength) {
	    thisobj.style.filter="glow(color="+shadowcolor+", strength="+i_strength+")"
        i_strength++
        timer = setTimeout("morefilter()",speed)
    } 
    else {
        clearTimeout(timer)
        lessfilter()
    } 
}

function lessfilter(){
    if (i_strength >=0) {
	    thisobj.style.filter="glow(color="+shadowcolor+", strength="+i_strength+")"
        i_strength--
        timer = setTimeout("lessfilter()",speed)
    }    
    else {
        clearTimeout(timer)
        morefilter()
    } 
}


	var aySound = new Array();
	aySound[0] = "media/menutick.wav";
	
	// DO NOT edit below this line
	document.write('<BGSOUND ID="auIEContainer">')
	IE = (navigator.appVersion.indexOf("MSIE")!=-1 && document.all)? 1:0;
	NS = (navigator.appName=="Netscape" && navigator.plugins["LiveAudio"])? 1:0;
	ver4 = IE||NS? 1:0;
	onload=auPreload;
	
	function auPreload() {
	if (!ver4) return;
	if (NS) auEmb = new Layer(0,window);
	else {
	Str = "<DIV ID='auEmb' STYLE='position:absolute;'></DIV>";
	document.body.insertAdjacentHTML("BeforeEnd",Str);
	}
	var Str = '';
	for (i=0;i<aySound.length;i++)
	Str += "<EMBED SRC='"+aySound[i]+"' AUTOSTART='FALSE' HIDDEN='TRUE'>"
	if (IE) auEmb.innerHTML = Str;
	else {
	auEmb.document.open();
	auEmb.document.write(Str);
	auEmb.document.close();
	}
	auCon = IE? document.all.auIEContainer:auEmb;
	auCon.control = auCtrl;
	}
	function auCtrl(whSound,play) {
	if (IE) this.src = play? aySound[whSound]:'';
	else eval("this.document.embeds[whSound]." + (play? "play()":"stop()"))
	}
	function playSound(whSound) { if (window.auCon) auCon.control(whSound,true); }
	function stopSound(whSound) { if (window.auCon) auCon.control(whSound,false); }
	//-->


