function CheckFeedback() {
	with (document.feedback) {
		if (name.value == '') {
			alert('Please enter your name.');
			return false;
		} else if (email.value == '') {
			alert('Please enter your email address.');
			return false;
		} else if((email.value.length <= 6) || (email.value.indexOf("@") == -1) || (email.value.indexOf(".") == -1)){
			alert('Sorry, your email address appears to be invalid. Please check it and try again');
			return false;
		} else if (message.value == '') {
			alert('Please enter your message.');
			return false;
		} else if (validate.value == '') {
			alert('Please enter the validation word shown in the image.');
			return false;
		} else if (validate.value.length != 5) { 
			alert('Validation word should be 5 letters long.');
			return false;
		}
			
	}
}
function PortfolioImage(i,t) {
	with (document.pimage) {
		src = "/images/portfolio/"+i;
		alt = t;
		title = t;
	}
}
function CheckFirst(TheMessage,TheLink) {
	var PopUpBox = confirm(TheMessage);
	if(PopUpBox)self.location=TheLink;
}
function isEmail(string) {
	if (string.search(/^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/) != -1) {
		return true;
	} else {
		return false;
	}
}
