<!-- Hide

function mySubmit() {
	if (document.buynow.pID.value == "0") {
		alert("Please select a size/frame option.");
	}else{
	document.forms.buynow.submit();
	}
}

function sendMail() {
		alert("Thank you. We'll be letting you know about special news at ScenicPrints.com.");
		document.forms.email.submit();
}

function EGCSubmit() {
	if (document.form.EGCRecip.value != document.form.EGCRecip2.value) {
		alert("Email address not confirmed.");
	}else{
	document.form.submit()
	}
}



function checkFields() {
	missinginfo = "";
	if (document.checkout.ship_first_name.value == "") {
	missinginfo += "\n     -  shipping first name";
	}
	if (document.checkout.ship_last_name.value == "") {
	missinginfo += "\n     -  shipping last name";
	}
	if (document.checkout.ship_address.value == "") {
	missinginfo += "\n     -  shipping address";
	}
	if (document.checkout.ship_city.value == "") {
	missinginfo += "\n     -  shipping city";
	}
	if (document.checkout.bill_first_name.value == "") {
	missinginfo += "\n     -  billing first name";
	}
	if (document.checkout.bill_last_name.value == "") {
	missinginfo += "\n     -  billing last name";
	}
	if (document.checkout.bill_address.value == "") {
	missinginfo += "\n     -  billing address";
	}
	if (document.checkout.bill_city.value == "") {
	missinginfo += "\n     -  billing city";
	}
	if (document.checkout.CCnum.value == "") {
	missinginfo += "\n     -  credit card number";
	}
	if (document.checkout.CCexp_month.value == "") {
	missinginfo += "\n     -  credit card expiration month";
	}
	if (document.checkout.CCexp_year.value == "") {
	missinginfo += "\n     -  credit card expiration year";
	}
	if ((document.checkout.email.value == "") || (document.checkout.email.value.indexOf('@') == -1) || (document.checkout.email.value.indexOf('.') == -1)) {
	missinginfo += "\n     -  email address";
	}

	if (missinginfo != "") {
	missinginfo ="_____________________________\n" + "You failed to correctly fill in your:\n" + missinginfo + "\n_____________________________" + "\nPlease re-enter and submit again.";
	alert(missinginfo);
	return false;
	} else return true;
}


var openWinPos = null;
var chasm = screen.availWidth;
var mount = screen.availHeight;
var w = 0;
var h = 0;
function newWin(page, name, w,h) {
	{ if (!openWinPos || openWinPos.closed)
       		{openWinPos = window.open(page,name,'status=0,scrollbars=1,resizable=1, toolbar=0, location=0,width=' + w + ',height=' + h + ',left=' + ((chasm - w - 10) * .5) + ',top=' + ((mount - h - 30) * .5));
 	} else {
	openWinPos.focus()
		}
	}
}

function openWin(url,windowName,w,h) {
	if ((navigator.appName.indexOf("Microsoft") != -1) || (2 < (navigator.appVersion + "3").charAt(0))) {
//		url         = "http://www.wyoming.com/";
		windowName  = "New";
		params      = "toolbar=0,";
		params     += "location=0,";
		params     += "directories=0,";
		params     += "status=0,";
		params     += "menubar=0,";
		params     += "scrollbars=1,";
		params     += "resizable=0,";
//		params     += "width=450,";
//		params     += "height=400";
		win = window.open(url, windowName, params);
		if (!win.opener) {
			win.opener = window;
		}
	}
}

function validated(string) {
    for (var i=0, output='', valid="1234567890"; i<string.length; i++)
       if (valid.indexOf(string.charAt(i)) != -1)
          output += string.charAt(i)
    return output;
} 

//-->
