// 
// (c)2001-2003 Design Ventures.  All rights reserved.
// 
// The code contained herein is copyrighted material and
// permission to use it is therefore denied.
//
// If you would like to use it for educational purposes
// you must obtain written permission from Design Ventures
// prior to using it.  Contact us either by email at
// permissions@dventures.com or by phone at (208)978-4790.
//
//


//    index.html :
	
function newImage(arg) {
	if (document.images) {
		rslt = new Image();
		rslt.src = arg;
		return rslt;
	}
}

function changeImages() {
	if (document.images && (preloadFlag == true)) {
		for (var i=0; i<changeImages.arguments.length; i+=2) {
			document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
		}
	}
}

var preloadFlag = false;
function preloadImages() {
	if (document.images) {
		home_on = newImage("img/home_on.gif");
		about_on = newImage("img/about_on.gif");
		services_on = newImage("img/services_on.gif");
		support_on = newImage("img/support_on.gif");
		contact_on = newImage("img/contact_on.gif");
		details_on = newImage("img/details_on.gif");
		order_on = newImage("img/order_on.gif");
		preloadFlag = true;
	}
}

function popup(plan,left_or_right)	{
	src = plan + ".html";
	order_src = "order_" + plan + ".html";
	leftpos = ( screen.width - 500 )/2;
	toppos = ( screen.height - 640 )/2;
	if(left_or_right == "right") {
		window.open(src,"planwindow","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=220,height=640,left=" + leftpos + ",top=" + toppos + "").focus();
		leftpos += 250;
		window.open(order_src,"orderwindow","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=220,height=640,left=" + leftpos + ",top=" + toppos + "").focus();
	} else {
		window.open(src,"planwindow","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=220,height=640,left=" + leftpos + ",top=" + toppos + "").focus();
	}
}

function popnew(theURL)	{
	leftpos = ( screen.width - 500 )/2;
	toppos = ( screen.height - 640 )/2;
	leftpos += 250;
	window.open(theURL,"orderwindow","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=220,height=640,left=" + leftpos + ",top=" + toppos + "").focus();
}



function newWindow(url,w,h) {
	window.open(url,"newwindow","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=no,width=" + w + "," + "height=" + h).focus();
}




