﻿
function idsh(){
	var thisform=document.korina;
	var mem_id = thisform.mem_id.value;
	
	if(thisform.mem_id.value==""){
		alert("请输入 ID");
		thisform.mem_id.focus();
		return;
	}else{
			NewWindow=window.open('/mypage/id-sh.asp?mem_id='+mem_id, 'newwindow', 'width=500,height=300');
	}
}

function join(){
	var thisform=document.korina;
		
		if(thisform.id_ok.value=="no"){
			alert("您的id已经存在");
			thisform.mem_id.focus();
			return;
		}
		
		if(thisform.mem_id.value==""){
			alert("请输入 ID");
			thisform.mem_id.focus();
			return;
		}
		
		if(thisform.name.value==""){
			alert("请输入 姓名");
			thisform.name.focus();
			return;
		}
				
		if(thisform.pass.value==""){
			alert("请输入 密码");
			thisform.pass.focus();
			return;
		}
		
		if(thisform.pass_ok.value==""){
			alert("请输入 密码确认");
			thisform.pass_ok.focus();
			return;
		}
		
		if(thisform.pass.value != thisform.pass_ok.value){
			alert("Invalid Password");
			thisform.pass.value="";
			thisform.pass_ok.value="";
			thisform.pass.focus();
			return;
		}						
		
		
		if(thisform.tel.value==""){
			alert("请输入 电话");
			thisform.tel.focus();
			return;
		}

		if(thisform.hp.value==""){
			alert("请输入 手机");
			thisform.hp.focus();
			return;
		}
				
		if(thisform.post.value==""){
			alert("请输入 邮编");
			thisform.post.focus();
			return;
		}
		
		if(thisform.address.value==""){
			alert("请输入 地址");
			thisform.address.focus();
			return;
		}		
		
		
		if(thisform.email.value==""){
			alert("请输入 E-Mail");
			thisform.email.focus();
			return;
		}	
		
		thisform.action="join_ok.asp";					
		thisform.submit();
}



function com_join(){
    var thisform    =   document.korina;
        if(thisform.id_ok.value=="no"){
            alert("您的id已经存在");
            thisform.mem_id.focus();
            return;
        }
        
        if(thisform.pass.value==""){
            alert("请输入 密码");
            thisform.pass.focus();
            return;
        }

        
        if(thisform.pass_ok.value==""){
            alert("请输入 密码确认");
            thisform.pass_ok.focus();
            return;
        }
        
        if(thisform.pass.value != thisform.pass_ok.value){
            alert("Invalid Password");
            thisform.pass.value="";
            thisform.pass_ok.value="";
            thisform.pass.focus();
            return;
        }	           


        if(thisform.com_name.value==""){
            alert("请输入 公司名");
            thisform.com_name.focus();
            return;
        }	            	            
        
        if(thisform.com_cname.value==""){
            alert("请输入 法定代表人姓名");
            thisform.com_cname.focus();
            return;
        }
       /* 
        if(thisform.com_number1.value=="" || thisform.com_number2.value=="" || thisform.com_number3.value==""){
            alert("사업자 번호를 입력 해주세요");
            thisform.com_number1.focus();
            return;
        }	            
					               */

        if(thisform.com_year.value==""){
            alert("请输入 成立日期");
            thisform.com_year.focus();
            return;
        }	            

        if(thisform.com_mem.value==""){
            alert("请输入 职员数");
            thisform.com_mem.focus();
            return;
        }	            
        
        
        if(thisform.post.value==""){
            alert("请输入 邮编");
            thisform.post.focus();
            return;
        }	            
        
        if(thisform.address.value==""){
            alert("请输入 地址");
            thisform.address.focus();
            return;
        }	

        
        thisform.action="compny_join_ok.asp";
        thisform.submit();
        	            
}


    function com_modify(){
        var thisform=document.korina;
            
            if(thisform.pass.value==""){
                alert("请输入 密码");
                thisform.pass.focus();
                return;
            }

            if(thisform.pass_ok.value==""){
                alert("请输入 密码确认");
                thisform.pass_ok.focus();
                return;
            }


            if(thisform.pass.value != thisform.pass_ok.value){
                alert("Invalid Password.");
                thisform.pass.value="";
                thisform.pass_ok.value="";
                thisform.pass.focus();
                return;
            }
                        

            if(thisform.com_mem.value==""){
                alert("请输入 名");
                thisform.com_mem.focus();
                return;
            }

            if(thisform.post.value==""){
                alert("请输入 邮编");
                thisform.post.focus();
                return;
            }

            if(thisform.address.value==""){
                alert("请输入 地址");
                thisform.address.focus();
                return;
            }


            if(thisform.address_detail.value==""){
                alert("请输入 地址");
                thisform.address_detail.focus();
                return;
            }

            if(thisform.com_email.value==""){
                alert("请输入 E-Mail");
                thisform.com_email.focus();
                return;
            }
                  
            thisform.action="mypage-com-edit_ok.asp";
            thisform.submit();
            
                                    
    }
