// JScript source code

var szHomePage = "indexx.htm"; // used in case we switch web servers

function checkBrowser(){
	// caches browser caps in an object for easy access
	this.ver=navigator.appVersion
	this.dom=document.getElementById?1:0
	this.ie7=(this.ver.indexOf("MSIE 7")>-1 && this.dom)?1:0;
	this.ie6=(this.ver.indexOf("MSIE 6")>-1 && this.dom)?1:0;
	this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom)?1:0;
	this.ie4=(document.all && !this.dom)?1:0;
	this.ns5=(this.dom && parseInt(this.ver) >= 5)?1:0;
	this.ns4=(document.layers && !this.dom)?1:0;
	this.ok=(this.ie7||this.ie6||this.ie5||this.ns5)
	this.ms=(this.ie7||this.ie6||this.ie5||this.ie4)
	this.ns=(this.ns5||this.ns4)
	
	this.isie=(this.ie6||this.ie5||this.ie4||this.ie7)
	this.isns=(this.ns5||this.ns5)
	
	return this
}

// object for determining browser caps
var thisbrowser=new checkBrowser()

// pre-load rollovers
var imgTab = new Image; imgTab.src = "images/tab.gif";
var imgTabHover = new Image; imgTabHover.src="images/tab2.gif";	

function hoverLink(szImg, szA){
	var obj=document.getElementById(szImg);
	if (obj!=null) obj.src="images/tab2.gif";
	
	obj=document.getElementById(szA);
	if (obj!=null) obj.style.color="green";
	
	return;
}

function unhoverLink(szImg, szA){
	var obj=document.getElementById(szImg);
	if (obj!=null) obj.src="images/tab.gif";
	
	obj=document.getElementById(szA);
	if (obj!=null) obj.style.color="black";
	
	return;
}


function clickLink(szURL, szDest){
	if (thisbrowser.isie){
		if (szDest!=null) window.parent.frames(szDest).location.replace(szURL);			
		else window.open(szURL, "_blank");		
	}
	return;
}



// used in several places so only initialize once
var szaMonths= new Array("January","February","March","April","May","June","July","August","September","October","November","December");

function forceFrame(szpFrame){
	// forces pages made to display in their appropriate frames	
	if (window.name!=szpFrame){
		window.location.href=szHomePage;
	}	
}


function drawBackground(iLines){
	// draws and positions the background image for most pages at the specified size
	document.writeln("<div id='background'>");
	document.writeln("    <div><img src='images/ledgetop.jpg'></div>");
	
	if (iLines==null) iLines=3;
	for(i=0;i<iLines-2;i++){	
		document.writeln("    <div><img src='images/ledger.jpg'></div>");
	};
	
	document.writeln("    <div><img src='images/ledgebottom.jpg'></div>");
	document.writeln("</div>");
}



function drawCopyright(){
	// draws the copyright notification at the bottom of most pages
	document.write("<div id='copyright' align='center' style='font-family: tahoma, verdana; font-size: 10px; position: absolute; width: 588; ");
	if (thisbrowser.ns5==1){
		document.write("line-height: 1px;");
	} else {
		document.write("line-height: 12px;");
	};
	
	document.writeln("'>&nbsp;<br>");
	document.writeln("<sup>©</sup>Copyright&nbsp;2001-2007,&nbsp;LL&nbsp;Associates<br>Quickbooks<sup>®</sup> and Quicken<sup>®</sup> are registered trademarks of Intuit, Inc.<br>LL Associates is not an agent of Intuit and assumes no liability for the use of Quickbooks<sup>®</sup> software,<br>Quicken<sup>®</sup> software or any other Intuit product.");
	document.writeln("<br>&nbsp;</div>");
}




