<!--
function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_showHideLayers() { //v6.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }
    obj.visibility=v; }
}

function popwin(url,w,h) { 
window.open(url,'new','toolbar=0,status=0,menubar=0,scrollbars=0,width='+w+',height='+h+',resizable=0')
}

function popwin1(url,w,h) { 
window.open(url,'new','toolbar=0,status=0,menubar=0,scrollbars=1,width='+w+',height='+h+',resizable=0')
}

function Conf(object) {
if (confirm("คุณต้องการลบ จริงหรือเปล่า ?")==true) {
return true;
}
return false;
}

function confEdit(object) {
	if (confirm("คุณต้องการเปลี่ยนสถานะ จริงหรือเปล่า ?")==true) {
		return true;
		}
	return false;
}

function check_userpass() {
t_c=event.keyCode
if ((t_c < 13) || (t_c >13 && t_c < 45) || (t_c > 45 && t_c < 48) || (t_c > 57 && t_c < 65) || (t_c > 90 && t_c < 95) || (t_c > 95 && t_c < 97) || (t_c > 122)) {
event.returnValue = false;
alert("- เป็นตัวอักษรภาษาอังกฤษ (a-z, A-Z) ,ตัวเลข (0-9) , \n เครื่องหมาย \"-\" หรือ \"_\" เท่านั้น  \n- ห้ามมีการเว้นวรรค");
}
}

function check_number() {
t_c=event.keyCode
if (t_c != 13 && (t_c < 48) || (t_c > 57)) {
event.returnValue = false;
alert("ต้องเป็นตัวเลขเท่านั้น...  \nกรุณาตรวจสอบข้อมูลของท่านอีกครั้ง...");
}
}

function check_point() {
t_c=event.keyCode
if ((t_c >13 && t_c < 45) || (t_c > 46 && t_c < 48) || (t_c > 57)) {
event.returnValue = false;
alert("ต้องเป็นตัวเลขหรือจุดทศนิยมเท่านั้น... \nกรุณาตรวจสอบข้อมูลของท่านอีกครั้ง...");
}
}

function check_email() {
t_c=event.keyCode
if ((t_c < 13) || (t_c >13 && t_c < 45) || (t_c > 46 && t_c < 48) || (t_c > 57 && t_c < 64) || (t_c > 90 && t_c < 95) || (t_c > 95 && t_c < 97) || (t_c > 122)) {
event.returnValue = false;
alert("ต้องเป็นตัวอักษรภาษาอังกฤษเท่านั้น  \nและห้ามมีการเว้นวรรคเด็ดขาด \nกรุณาตรวจสอบข้อมูลของท่านอีกครั้ง...");
}
}

//-->