
	function alterimage(Message, Image, ImageName){
		if((Ver_number.indexOf('3.')>=0)||(Ver_number.indexOf('4.')>=0)||(Ver_number.indexOf('5.')>=0)||(Ver_number.indexOf('6.')>=0)) {
			ImageSrc=Image;
			window.status = Message;
			document.images[ImageName].src=ImageSrc;
			}
		}

//***************************************************************************
function open_window(filename, windowname, properties) {
	
	var currentwidth, currentheight;
	
	
	var isfound, re;
	re = /laarc|source|herts|action/; //create regexp to check if this is about page - so can make it bigger
	isfound = filename.search(re);
	if (isfound == -1){ // about not found  in filename
		currentheight = ((screen.height/100) * 80);
		currentwidth = ((screen.width/100) * 88);
	}else{
		currentheight = ((screen.height/100) * 80); 
		currentwidth = ((screen.width/100) * 90); //make about wider
	}
	window.open(filename, windowname, properties + ",width=" + currentwidth + ",height=" + currentheight);
}
//***************************************************************************

function CheckScreenHeight(urlinput){
//var urltxt = "default.asp";
var urltxt = urlinput;
var topbanner = 85;
var restofTable = document.body.clientHeight - topbanner;

urltxt = urltxt + "?h=" + restofTable;
window.location.href = urltxt;

}
//***************************************************************************
function CheckOverURL(){

	//check if url field blank
	if (document.contactform.joburl.value == "") {
		alert("No URL to check, please enter the web address in the Job URL field");
	}else{
		var isfound, re, urladdress;
		re = /http:/; //create regexp to check if this is about page - so can make it bigger
		isfound = document.contactform.joburl.value.search(re);
		if (isfound == -1){ // http not found  in url append it
			urladdress = "http://" + document.contactform.joburl.value;
		}else{
			urladdress = document.contactform.joburl.value
		}
		open_window(urladdress, 'new_win', 'resizable=no,scrollbars=yes,toolbar=yes,location=no,directories=no,status=no,menubar=no,top=50,left=50,resizable=yes');
		document.contactform.joburl.value = urladdress;
	}
}
//***************************************************************************
function CheckOverForm(){

	//check if any field blank then stop submit
	var msg;
	msg = "";
	if (document.contactform.username.value == "") {
		msg = msg + "Please enter your name";
	}
	
	if (document.contactform.useremail.value == "") {
		if (msg != ""){ msg = msg + "\n"};
		msg = msg + "Please enter your email";
	}else{
		
		var isfound, re;
		re = /@/; //create regexp to check if email looks ok
		isfound = document.contactform.useremail.value.search(re);
		if (isfound == -1){ // @ not found  in string
			if (msg != ""){ msg = msg + "\n"};
			msg = msg + "Please enter a valid email address";
		}
	}
	
	if (document.contactform.qstr.value == "job") {
		if (document.contactform.joburl.value == ""){
			if (msg != ""){ msg = msg + "\n"};
			msg = msg + "Please enter the job URL you wish to submit";
		}
	}else{
		if (document.contactform.comment.value == "") {
			if (msg != ""){ msg = msg + "\n"};
			msg = msg + "Please enter your comment";
		}
	}
	if (msg != ""){
		alert(msg);
	}else{
		document.contactform.submit();
	}
}
//***************************************************************************