function setStyle_func(obj, stylevar, styleval){
	obj.style[stylevar]=styleval
}

function checkform_func(form){
	formlen = form.length
	submitform = 1
	for (i=0;i<formlen;i++){
		if (form.elements[i].type == "text" || form.elements[i].type == "textarea" || form.elements[i].type == "file" || form.elements[i].type == "password"){
			if (form.elements[i].value == "" ){
				submitform = 0
			}
		}
	}

	if (submitform == ""){
		alert("Please fill in all fields!!")
	} else {
		form.submit()
	}
}

function gotourl_func(url){
	location.href = url
}

function confdel_func(txt, url){
	confvar = confirm(txt)
	if (confvar){
		location.href=url
	}
}

function prmpt_func(txt1, txt2, url){
	prmptvar = prompt(txt1, txt2)
	if (prmptvar){
		location.href=url+"&newtxt="+prmptvar
	}
}

function openWin_func(url, winName, toolbar, status, scrollbars, resizable, menubar, width, height, topleft, fullscreen) {
	if (navigator.appName == "Netscape" &&  parseFloat( navigator.appVersion ) > 3.0 ){
		window.open(url, winName, "Toolbar="+toolbar+",status="+status+","+fscreen+",scrollbars="+scrollbars+",resizable="+resizable+",menubar="+menubar+",width="+width+",height="+height+",screenX=0,screenY=0");
	} else if (navigator.appName == "Microsoft Internet Explorer" && parseFloat( navigator.appVersion ) > 3.0 ) {
		if (topleft == 1){
			screenx = 0
			screeny = 0
		} else {
			sreenw = screen.width
			sreenh = screen.height
			screenx = (sreenw - width)/2
			screeny = (sreenh - height)/2
		}
		if (fullscreen == 1){
			fscreen = "fullscreen"
	  	} else {
			fscreen = ""
	  	}
		window.open(url, winName, "Toolbar="+toolbar+",status="+status+","+fscreen+",scrollbars="+scrollbars+",resizable="+resizable+",menubar="+menubar+",width="+width+",height="+height+",left="+screenx+",top="+screeny);
	}
}

function isNo_func(val, form){
	if (isNaN(val)){
		alert("The salary field must be a number!")
	} else {
		form.submit()
	}
}