function buyNow(str) {
	//window.open('http://www.jsinfotech.com/contact.php','JSInfotech','') 
    //newwindow = window.open("http://www.jsinfotech.com/support.php?d=MyLuchyDomains.com?" + str, 'JSInfotech', 'width=450,height=450,resizable=yes,scrollbars=yes');
    //newwindow.focus();
	document.location.href='/buyNow.php?' + str;
}

function popupSupport() {
    newwindow = window.open("http://www.jsinfotech.com/support.php?d=MyLuchyDomains.com", 'JSInfotech', 'width=450,height=450,resizable=yes,scrollbars=yes');
    newwindow.focus();
}


function validateAndSubmit() {
	var form = document.forms[0];
	var userName = form.userName.value;
	var email = form.email.value;
	var subject = form.subject.value;
	var comment = form.comment.value;
	var message = "";

	if (userName.length == 0){
		message += "Name missing.";
	}

	if (email.length == 0){
		if (message.length != 0) {
			message += "\n";
		}

		message += "Email missing.";
	}

	if (subject.length == 0){
		if (message.length != 0) {
			message += "\n";
		}

		message += "Subject missing.";
	}

	if (comment.length == 0){
		if (message.length != 0) {
			message += "\n";
		}
		message += "Comment missing.";
	}

	if (message.length != 0) {
		if (userName.length == 0) {
			form.userName.focus();
		} else if (email.length == 0) {
			form.email.focus();
		} else if (subject.length == 0) {
			form.subject.focus();
		} else if (comment.length == 0) {
			form.comment.focus();
		}

		alert(message);
	} else {
		form.sign.value = "submit";
		form.submit();
	}
}

function closeWindow() {
	window.opener.focus();
	window.close();
}
