<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%> 
<%Session.CodePage=936%> 
<!--#include file="../../conn/conn.asp" -->
<!--#include file="../../Inc/Commoncode.asp" -->
<!--#include file="../../inc/CommonFunction.asp"-->
<!--#include file="../../inc/sendmail.asp" -->
<!--#include file="../checkvalid.asp" -->
<!--#include file="../../inc/md5.asp"-->
<!--#include file="../../API/API_Config.asp"-->
<!--#include file="../../API/API_Function.asp"-->
<%sUploadDir=UpFilesPath("Person")
If Not FRAdminLevel(302) Then Call ErrorMsg()
Response.Expires = 0 
Response.CacheControl = "no-cache" 
Response.ExpiresAbsolute = Now() - 1 
%>
<html>
<head>
<title>添加简历</title>
<link href="../css/style<%=sk%>.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="../inc/input.js"></script>
<script language="javascript" src="../Inc/Admin.js"></script>
<script language="JavaScript">
function show(str,strs)
{
	if (document.getElementById(str).checked==true)
	{document.getElementById(strs).style.display="block";}
	else
	{document.getElementById(strs).style.display="none";}
}
function GetProfession(professionid)
{
document.frames["professionframe"].location.replace("../../inc/getprofession2.asp?professionid="+professionid);
}
function GetPosition(positionid)
{
document.frames["positionframe"].location.replace("../../inc/getposition2.asp?positionid="+positionid);
}
<!--
//功能：去掉字符串前后空格
//返回值：去掉空格后的字符串
function fnRemoveBrank(strSource)
{
 return strSource.replace(/^\s*/,'').replace(/\s*$/,'');
}
function String.prototype.lenB()
{
return this.replace(/[^\x00-\xff]/g,"**").length;
}
function Juge(theForm)
{
	  if (fnRemoveBrank(theForm.login.value)== "")
	{
	 alert("请输入会员帐号!");
    theForm.login.focus();
    return (false);
	}
	var objv = theForm.login.value;
    var pattern = /^[A-Za-z0-9]{4,20}$/;
    flag = pattern.test(objv);
    if (!flag) 
    {
     alert("会员帐号：要求为4-20个字母或数字！请重新输入。");
     theForm.login.focus();
     return(false);
     }
    if (fnRemoveBrank(theForm.pwd.value)== "")
	{
	 alert("请输入会员密码!");
    theForm.pwd.focus();
    return (false);
	}
	var objv = theForm.pwd.value;
    var pattern = /^[A-Za-z0-9]{4,20}$/;
    flag = pattern.test(objv);
    if (!flag) 
    {
     alert("会员密码：要求为4-20个字母或数字！请重新输入。");
     theForm.login.focus();
     return(false);
     }
	
  if (theForm.pwd.value != theForm.pwd1.value)
  {
    alert("两次输入密码不一致，请重新输入!");
    theForm.pwd.focus();
    return (false);
  }	 
  if (theForm.user_type.value == "")
  {
    alert("请选择会员服务类型!");
    theForm.user_type.focus();
    return (false);
  }
  if (theForm.startdate.value == "")
  {
    alert("请正确填写开始时间!");
    theForm.startdate.focus();
    return (false);
  }
  if (theForm.enddate.value == "")
  {
    alert("请正确填写结束时间!");
    theForm.enddate.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.names.value) == "")
  {
    alert("请输入姓名!");
    theForm.names.focus();
    return (false);
  }
  todays=new Date();
 // birthb=new Date(theForm.birth.value);
   var birtha=theForm.birth.value; 
   var birthb=birtha.split("-");
   
  if (fnRemoveBrank(theForm.birth.value) == "")
  {
    alert("请输入出日期!");
    theForm.birth.focus();
    return (false);
  }else
  if (todays.getYear()-12<=birthb[0])
  {
   alert("出生日期"+birtha+"至今必须大于12年!");
    theForm.birth.focus();
    return (false);
	}
  if (fnRemoveBrank(theForm.idcard.value) == "")
  {
    alert("请输入证件编号!");
    theForm.idcard.focus();
    return (false);
  }
   if (fnRemoveBrank(theForm.edu.value) == "")
  {
    alert("请选择最高学历!");
    theForm.edu.focus();
    return (false);
  }
   if (fnRemoveBrank(theForm.province.value) == "")
  {
    alert("请选择所在省份!");
    theForm.province.focus();
    return (false);
  }
//   if (fnRemoveBrank(theForm.school.value) == "")
//  {
//    alert("请填写毕业学校!");
//    theForm.school.focus();
//    return (false);
//  }
  if (fnRemoveBrank(theForm.tel.value) == ""&&fnRemoveBrank(theForm.mobile.value) == "")
  {
    alert("联系电话或手机至少填写一项!");
    theForm.tel.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.tel.value) != "")
  {
	  var objv = fnRemoveBrank(theForm.tel.value);
	  var pattern = /^[0-9\s+.-]+$/;
	  flag = pattern.test(objv);
	  if(!flag)
	  {
		alert("联系电话：格式不正确!请重新输入。");
		theForm.tel.focus();
		return (false);
	   }
  }
  var objv = fnRemoveBrank(theForm.email.value);
  var pattern = /^([a-zA-Z0-9_-])+(\.([a-zA-Z0-9_-])+)*@([a-zA-Z0-9_-])+(\.([a-zA-Z0-9_-])+)+$/;
  flag = pattern.test(objv);
  if(!flag)
  {
    alert("电子邮件：格式不正确！请重新输入。");
	theForm.email.focus();
	return (false); 
  } 
  if (fnRemoveBrank(theForm.post.value) != "")
  {
	  var objv = fnRemoveBrank(theForm.post.value);
	  var pattern = /^[0-9]+$/;
	  flag = pattern.test(objv);
	  if(!flag)
	  {
		alert("邮政编码：要求为数字!请重新输入。");
		theForm.post.focus();
		return (false);
	   }
   }
  if (fnRemoveBrank(theForm.url.value) != "")
  {
	  if(theForm.url.value.indexOf("http://")==-1)
	  {
		alert("个人主页：必须包括“http://”，请完整填写。");
		theForm.url.focus();
		return (false);
	   }
   }
  if (fnRemoveBrank(theForm.title.value) == "")
  {
    alert("请输入简历名称!");
    theForm.title.focus();
    return (false);
  }
if (document.getElementById("education").checked==true)
{
  if (fnRemoveBrank(theForm.edu_start_year.value) == "0")
  {
    alert("请选择时间!");
    theForm.edu_start_year.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.edu_start_month.value) == "0")
  {
    alert("请选择时间!");
    theForm.edu_start_month.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.edu_school.value) == "")
  {
    alert("请输入学校名称!");
    theForm.edu_school.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.mainprofession.value) == "")
  {
    alert("请选择专业!");
    theForm.mainprofession.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.subprofession.value) == "")
  {
    alert("请选择专业!");
    theForm.subprofession.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.edu_edu.value) == "")
  {
    alert("请选择学历!");
    theForm.edu_edu.focus();
    return (false);
  }
}
if (document.getElementById("train").checked==true)
{
  if (fnRemoveBrank(theForm.train_start_year.value) == "0")
  {
    alert("请选择培训时间!");
    theForm.train_start_year.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.train_start_month.value) == "0")
  {
    alert("请选择培训时间!");
    theForm.train_start_month.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.train_train.value) == "")
  {
    alert("请输入培训机构!");
    theForm.train_train.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.train_course.value) == "")
  {
    alert("请输入培训课程!");
    theForm.train_course.focus();
    return (false);
  }
}
if (document.getElementById("lang").checked==true)
{
  if (fnRemoveBrank(theForm.language.value) == "0")
  {
    alert("请选择外语语种!");
    theForm.language.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.master.value) == "0")
  {
    alert("请选择掌握程度!");
    theForm.master.focus();
    return (false);
  }
}
if (document.getElementById("work").checked==true)
{
  if (fnRemoveBrank(theForm.work_start_year.value) == "0")
  {
    alert("请选择时间!");
    theForm.work_start_year.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.work_start_month.value) == "0")
  {
    alert("请选择时间!");
    theForm.work_start_month.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.work_comname.value) == "")
  {
    alert("请输入公司名称!");
    theForm.work_comname.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.work_ecoclass.value) == "")
  {
    alert("请选择公司性质!");
    theForm.work_ecoclass.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.work_trade.value) == "")
  {
    alert("请选择所属行业!");
    theForm.work_trade.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.mainposition.value) == "")
  {
    alert("请选择岗位!");
    theForm.mainposition.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.subposition.value) == "")
  {
    alert("请选择岗位!");
    theForm.subposition.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.work_dept.value) == "")
  {
    alert("请输入所在部门!");
    theForm.work_dept.focus();
    return (false);
  }
  if (fnRemoveBrank(theForm.work_place.value) == "")
  {
    alert("请输入职位名称!");
    theForm.work_place.focus();
    return (false);
  }
}
  if (theForm.trade.value == "")
  {
    alert("请选择希望行业类别!");
	theForm.trades.focus();
    return (false);
  }
  if (theForm.position.value == "")
  {
    alert("请选择希望工作岗位!");
	theForm.positions.focus();
    return (false);
  }
  if (theForm.workadd.value == "")
  {
    alert("请选择希望工作地区!");
	theForm.workadds.focus();
    return (false);
  }
}
 
function jumpwindow(i){   
  document.all.bodyly.style.display="block";   
  document.all.bodyly.style.width=document.body.clientWidth;   
  document.all.bodyly.style.height=document.body.clientHeight; 
  document.getElementById("jumply"+i).style.display='block'; 
  document.getElementById("jumply"+i).style.top=document.documentElement.scrollTop+40;   
  document.getElementById("jumply"+i).style.left=document.body.clientWidth/2-250;  
  }   
function unwindow(i){
  document.getElementById("jumply"+i).style.display='none';
  document.all.bodyly.style.display='none';
  } 
function checkUserExist(theForm){
	if (fnRemoveBrank(personform.login.value)== "") {
		alert ('请输入会员帐号 ！');
		personform.login.focus();
		return false;
	}else{
		window.open("checkpmemberuser.asp?login="+personform.login.value,"","width=340,height=200,scrollbars=no");
	}
	return false;
}
function changetype(typeid,endyear,endmonth,endday,outlay)
{
var today;
today=new Date(); 
month=today.getMonth();
year=today.getYear();
day=today.getDate(); 
document.personform.startdate.value=year+'-'+(month+1)+'-'+day;
document.personform.enddate.value=endyear+'-'+endmonth+'-'+endday;
}
-->
</script>
</head>
<body>
<table width="98%" border="0" align="center" cellpadding="2" cellspacing="1" class="tableBorder">
  <tr> 
	   <th  height=25 class="tableHeaderText">个人会员管理</th>
  </tr>
  <form action="pmember_searchlist.asp" method="post">
    <tr bgcolor="7897E0">
      <td height="28" align="left"><font color="ff6600"><b class="style11">　管理选项</b></font>：&nbsp;<a href="pmember_searchlist.asp">管理首页</a> |  <a href="pmember_searchlist.asp">人才管理</a> | <a href="resume_searchlist.asp" target="main">简历管理</a> | <a href="person_addresume.asp" target="main">简历添加</a> | <a href="resume_search.asp" target="main">人才查询</a> | [<a href="javascript:location.reload()">刷新页面</a>]</td>
    </tr>
    <tr bgcolor="7897E0">
      <td height="28" align="left"><font color="ff6600"><b class="style11">　二级选项</b></font>： <a href="?operate=0">待审人才</a> | <a href="?operate=1">已审人才</a> | <a href="?operate=2">精英人才</a> | <a href="?operate=3">待审照片</a> | <a href="?operate=4">已过期</a> | <a href="?operate=5">一周内到期</a> | <a href="?operate=6">30天内到期</a></td>
    </tr>
    <tr bgcolor="7897E0">
      <td height="28" align="left"><font color="ff6600"><b class="style11">　服务选项</b></font>：
        <%set rss=conn.execute("select * from job_Group where Group_membertype=1")
	  if not rss.eof then
	  do while not rss.eof%>
        <a href="?operate=<%=operate%>&group=<%=rss("Group_id")%>"><%=rss("Group_name")%></a> |
      <%rss.movenext
		loop
		end if%></td>
    </tr>
    <tr bgcolor="7897E0"> 
      <td height="28" align="left"> 
          &nbsp;&nbsp;&nbsp;&nbsp;关键字： 
          <input name="keyword" type="text" id="keyword" value="<%=keyword%>" size="20">
          <select name="segment" size="1" id="segment">
            <option value="pmember_login" <%if segment="pmember_login" then response.Write "selected"%>>会员帐号</option>
            <option value="pmember_name" <%if segment="pmember_name" then response.Write "selected"%>>真实姓名</option>
            <option value="pmember_email" <%if segment="pmember_email" then response.Write "selected"%>>邮箱地址</option>
            <option value="pmember_tel" <%if segment="pmember_tel" then response.Write "selected"%>>联系电话</option>
            <option value="pmember_mob" <%if segment="pmember_mob" then response.Write "selected"%>>手机号码</option>
          </select>
          <input name="Submit" type="submit" class="inputs" value="搜索">
     &nbsp;<a href="pmember_searchlist.asp?step=reload">刷新账户状态</a> （刷新数据库，将<span class="STYLE2">过期</span>个人用户转成默认用户）</td>
    </tr>
  </form>
</table>
<iframe height=0 width=0 src="" id="professionframe"></iframe>
<iframe height=0 width=0 src="" id="positionframe"></iframe>
<div id="bodyly" style="position:absolute;top:0px;FILTER: alpha(opacity=80);background-color:#333; z-index:0;left:0px;display:none;"></div>
<div id="SearchDivhire" style="border:1px #8BC3F6 solid; position:absolute;background-color:#FFFFFF;width:560px;font-size:12px;  z-index:999; display:none;">
<div class="memmenul">
	<div onmousedown=MDown(SearchDivhire) title="可以随意拖动" style="width:538px; cursor:move;font-size:13px;color:#166AB6; font-weight:bold;" class="leftmenutit"><span style="float:right;font-size:12px; padding-right:10px; font-weight:normal; cursor:pointer;" onClick="unSearchLayers();">[关闭]</span><span id="wintit"></span><span style="font-size:12px; padding-left:10px; font-weight:normal;">最多可选择5个</span></div>
    <form name="form3" id="form3">
	<div style="width:100%;">
		<div id="changbox" style="float:left; margin-left:10px; margin-right:6px; margin-top:10px;"></div>
		<div id="changboxs" style="float:left; margin-left:10px;width:408px;margin-top:10px; display:none;"></div>
		<div id="bigclass" style="margin-left:10px;width:528px;margin-top:4px;"></div>
		<div id="smallclass" style="margin-left:10px;width:528px;margin-top:4px; line-height:150%; height:150px; overflow:auto"></div>
		<div id="checktitle" style="margin-left:10px; width:528px; margin-top:8px; font-size:13px; font-weight:bold;">您已经选择的是：<span style="cursor:pointer;font-size:12px; font-weight:bold; color:#FF0000" onClick="DelAllItem();">清空所有选项</span></div>
		<div id="selectitem" style="margin-left:10px; width:528px; height:40px;margin-top:4px; border:1px dashed #cccccc"></div>
		<div id="selectok" style="margin-left:10px; margin-top:4px; text-align:right; padding-right:40px;"></div>
	</div>
</form>
</div>
</div>
<%Action=trim(Request("Action"))
Select Case Action
	Case "Addnew"
		Call Addone()
	Case "SaveAddone"
		Call SaveAddone()
	Case "Deledu"
		Call Deledu()
	Case "Deltrain"
		Call Deltrain()
	Case "Dellang"
		Call Dellang()
	Case "Delwork"
		Call Delwork()
	Case Else
		Call addone()
End Select

if FoundErr=True then
	call Show_Err()
end if
%>
<%Sub addone()%>
<table width="98%" border="0" align="center" cellpadding="2" cellspacing="1" style="font-size:12px; line-height:20px;">
<form name="personform" action="person_addresume.asp?action=SaveAddone" method="post" onSubmit="return Juge(this)">
  <tr> 
	   <th  height=25 colspan="5" class="tableHeaderText">添加人才信息</th>
  </tr>
<tr > 
        <td height=25 colspan="5"><font color="#FF0000"><strong>基本资料</strong></font></td>
      </tr>
      <tr > 
        <td width="129" align="right"><FONT color=#ff6600>＊</FONT>会员帐号：</td>
        <td colspan="4"><input name=login id="login" size=20 maxlength=20> 
        （为字母或数字，4-20个字符） 
          <input name="checkUsername" type="button" class="inputs" onClick="checkUserExist();" value="查看会员帐号是否占用"></td>
      </tr>
      <tr> 
        <td align="right"><FONT color=#ff6600>＊</FONT>会员密码：</td>
        <td colspan="4"> <input name="pwd" type="password" id="pwd" value="" size="20" maxlength="20">          （为字母或数字，4-20个字符）</td>
      </tr>
      <tr> 
        <td align="right"><FONT color=#ff6600>＊</FONT>确认密码：</td>
        <td colspan="4"> <input name="pwd1" type="password" id="pwd1" value="" size="20" maxlength="20"></td>
      </tr>			   
       <tr> 
        <td align="right"><FONT color=#ff6600>＊</FONT>初始点数：</td>
        <td colspan="4"> <input name="consume" type="text" id="consume" value="0" size="20" maxlength="20">
          （为数字）</td>
      </tr>
       <tr>
         <td align="right"><FONT color=#ff6600>＊</FONT>服务类型：</td>
         <td colspan="4"><%sql="select * from JOB_Group where Group_membertype=1"
set rs1=server.createobject("adodb.recordset")
rs1.open sql,conn,1,1
if not rs1.eof then
do while not rs1.eof
response.Write "<input type='radio' name='user_type' value='"&rs1("Group_id")&"' class=checkbox onclick='changetype(this.value,"&year(UserTypeDate(rs1("Group_id")))&","&month(UserTypeDate(rs1("Group_id")))&","&day(UserTypeDate(rs1("Group_id")))&","&UserTypeoutlay(rs1("Group_id"))&")'"
if rs1("Group_IsDefault") then response.Write " checked"
response.Write ">"&rs1("Group_name")
rs1.movenext
loop
end if
rs1.close
set rs1=nothing
%></td>
       </tr>
       <tr>
         <td align="right"><FONT color=#ff6600>＊</FONT>帐户时限：</td>
         <td colspan="4">从
			<input name="startdate" type="text" size="10" readonly onClick="fPopUpCalendarDlg(startdate);return false" id=startdate value="<%=date()%>">
          <img src="../images/calendar_bnt.gif" style="cursor:hand;" align="absmiddle" onClick="fPopUpCalendarDlg(startdate);return false" width="34" height="21"> &nbsp;&nbsp; 至    
        &nbsp;<input name="enddate" type="text" size="10" readonly onClick="fPopUpCalendarDlg(enddate);return false" id=enddate value="">
        <img src="../images/calendar_bnt.gif" style="cursor:hand;" align="absmiddle" onClick="fPopUpCalendarDlg(enddate);return false" width="34" height="21">		</td>
       </tr>
  <tr>
    <td width="129" height="25" align="right"><font color="#ff7800">*</font>姓名：</td>
    <td width="148"><input name="names" id="names" maxlength="25" value="" /></td>
    <td width="97" align="right"><font color="#ff7800">*</font>性别：</td>
    <td width="247"><input type="radio" value="1" name="sex" checked />
男
  <input type="radio" value="2" name="sex" />
女 </td>
    <td width="133" rowspan="6" align="center" id="photoimg"><img height=140 src="../../UpFiles/Person/nophoto.gif" width=110 border=0 style="BORDER-RIGHT: #666666 1px solid; BORDER-TOP: #666666 1px solid; BORDER-LEFT: #666666 1px solid; BORDER-BOTTOM: #666666 1px solid"></td>
  </tr>
  <tr>
    <td align="right"><font color="#ff7800">*</font>出生日期：</td>
    <td><input type="text" name="birth" value="" id="birth" size="10" maxlength="10" onClick="fPopUpCalendarDlg(birth);return false" readonly /><img src="../images/calendar_bnt.gif" style="cursor:hand;" align="absmiddle" onClick="fPopUpCalendarDlg(birth);return false" WIDTH="34" HEIGHT="21"></td>
    <td align="right"><font color="#ff7800">*</font>证件类型：</td>
    <td><select name="cardtype" size="1" id="cardtype">
      <option value="0">身份证</option>
      <option value="1">驾证</option>
      <option value="2">军官证</option>
      <option value="3">护照</option>
      <option value="4">其它</option>
      </select>
      <input name="idcard" id="idcard" maxlength="20" value="" /></td>
    </tr>
  <tr>
    <td align="right">民族：</td>
    <td><select name="nation" id="nation">
      <option value=""></option>
<%
set rs=server.createobject("ADODB.Recordset")
sql="select * from job_nation"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("nation_id")&">"&rs("nation_name")&"</option>"
rs.movenext
loop
rs.close
%>
    </select></td>
    <td align="right">婚姻状况：</td>
    <td><select name="marriage" id="marriage">
      <option value=""></option>
  <%
sql="select * from job_marriage"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("marriage_id")&">"&rs("marriage_name")&"</option>"
rs.movenext
loop
rs.close
%>
    </select></td>
    </tr>
  <tr>
    <td align="right">政治面貌：</td>
    <td><select name="polity" id="polity">
      <option value=""></option>
<%
sql="select * from job_polity"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("polity_id")&">"&rs("polity_name")&"</option>"
rs.movenext
loop
rs.close
%>
    </select></td>
    <td align="right"><font color="#ff7800">*</font>最高学历：</td>
    <td><select name="edu">
      <option value="" selected="selected"></option>
  <%
sql="select edu_id,edu_name from job_edu order by edu_id desc"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("edu_id")&">"&rs("edu_name")&"</option>"
rs.movenext
loop
rs.close
%>
    </select></td>
    </tr>
  <tr>
    <td align="right">身高：</td>
    <td><input name="height" id="height" size="3" maxlength="3" value="" />
厘米</td>
    <td align="right">体重：</td>
    <td><input name="weight" type="text" id="weight" size="3" maxlength="3" value="" />
      公斤</td>
    </tr>
  <tr>
    <td align="right">职称：</td>
    <td><input name="zhicheng" id="zhicheng" maxlength="25" value="" /></td>
    <td align="right">个人照片：</td>
    <td><input name="member_logo" type="text" class="inputt" id="member_logo" size="20" readonly>
      <input name="upfile" type="button" class="inputs" onClick="window.open('../inc/job_up.asp?fromForm=personform&fromEdit=member_logo&saveTo=<%=sUploadDir%>&showPath=','','status=no,scrollbars=no,top=80,left=200,width=420,height=165')" value="浏览文件">
      <input type="button" name="button" id="button" class="inputs" value="预览" onClick="document.getElementById('photoimg').innerHTML='<img height=140 src=../../UpFiles/Person/'+member_logo.value+' width=110 border=0>'"></td>
    </tr>
  <tr>
    <td align="right">户口所在地：</td>
    <td colspan="4"><select name="hukouprovince" size="1" id="select5" onChange="changeProvince(document.personform.hukouprovince.options[document.personform.hukouprovince.selectedIndex].value)">
		<option value="">选择省</option>
		</select>		
		<select name="hukoucapital" onChange="changeCity(document.personform.hukoucapital.options[document.personform.hukoucapital.selectedIndex].value)">
		<option value="">选择市</option>
		</select>
		<select name="hukoucity">
		<option value="">选择区</option>
		</select></td>
    </tr>
  <tr>
    <td align="right"><font color="#ff7800">*</font>目前所在地：</td>
    <td colspan="4"><select name="province" size="1" id="select5" onChange="changeProvinces(document.personform.province.options[document.personform.province.selectedIndex].value)">
		<option value="">选择省</option>
		</select>		
		<select name="capital" onChange="changeCitys(document.personform.capital.options[document.personform.capital.selectedIndex].value)">
		<option value="">选择市</option>
		</select>
		<select name="city">
		<option value="">选择区</option>
		</select></td>
    </tr>
  <tr>
    <td align="right">毕业学校：</td>
    <td><input name="school" id="school" value="" maxlength="100" /></td>
    <td align="right">毕业时间：</td>
    <td><input type="text" name="graduate" value="" id="graduate" size="10" maxlength="10" onClick="fPopUpCalendarDlg(graduate);return false" readonly /><img src="../images/calendar_bnt.gif" style="cursor:hand;" align="absmiddle" onClick="fPopUpCalendarDlg(graduate);return false" WIDTH="34" HEIGHT="21"></td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td height="21" colspan="5" valign="middle"> 　联系方式</td>
  </tr>
  <tr>
    <td height="25" align="right"><font color="#ff7800">*</font>联系电话：</td>
    <td colspan="4"><input name="tel" id="tel" value="" size="40" maxlength="100" />
      联系电话或手机至少填一项</td>
  </tr>
  <tr>
    <td height="25" align="right" >手机：</td>
    <td colspan="4"><input name="mobile" id="mobile" maxlength="20" value="" />
      联系电话或手机至少填一项</td>
  </tr>
  <tr>
    <td align="right">聊天号码：</td>
    <td colspan="4"><input name="chat" id="chat" maxlength="100" value="" />
      <font color="#50463d">(QQ:123456;ICQ:345678;MSN:user@yjys.net)</font></td>
  </tr>
  <tr>
    <td align="right"><font color="#ff7800">*</font>电子邮件：</td>
    <td colspan="4"><input name="email" id="email" size="40" maxlength="100" value="" /></td>
  </tr>
  <tr>
    <td align="right">个人主页：</td>
    <td colspan="4"><input name="url" id="url2" size="40" maxlength="100" value="" /></td>
  </tr>
  <tr>
    <td align="right">通信地址：</td>
    <td colspan="4"><input name="address" size="40" maxlength="50" value="" /></td>
  </tr>
  <tr>
    <td align="right">邮政编码：</td>
    <td colspan="4"><input name="post" id="post2" size="6" maxlength="6" value="" /></td>
  </tr>
    <tr>
    <td height="21" colspan="5" valign="middle">新增简历名称（注：带<font color="#ff6600">＊</font>号为必填项）</td>
  </tr>
    <tr>
      <td width="129" height="25" align="right">简历名称：</td>
      <td colspan="4"><input name="title" id="title" value="" maxlength="25" />
        <span class="note">给简历命名，以区分多份不同的简历&nbsp;</span></td>
    </tr>
    <tr>
      <td align="right">选择人才类别：</td>
      <td colspan="4"><INPUT id=radUserGroup type=radio checked value=0 name=usergroup>
      普通 <INPUT id=radUserGroup type=radio value=1 name=usergroup>
      毕业生 
      <INPUT id=radUserGroup type=radio value=2 name=usergroup>高级人才</td>
    </tr>
  <tr>
    <td height="21" colspan="5" valign="middle"> 　我的简介</td>
  </tr>
  <tr>
    <td align="right">特点概括：</td>
    <td colspan="4"><input name="sumup" id="sumup" size="30" maxlength="20" value="" /></td>
  </tr>
  <tr>
    <td colspan="5"><font color="#993300">用最精练的几个字高度概括您最突出的求职优势。字数在10个字内。如：5年软件开发经验。</font></td>
    </tr>
  <tr>
    <td align="right">自我评价：</td>
    <td colspan="4"><font color="#993300">以下限2000个字符，用简洁的词语描述自己的综合能力。</font></td>
  </tr>
  <tr>
    <td align="right">&nbsp;</td>
    <td colspan="4"><textarea class="FieldText" id="appraise" style="FONT-SIZE: 12px" name="appraise" rows="10" cols="80"></textarea></td>
  </tr>
  <tr>
    <td height="21" colspan="5" valign="middle"> 　教育/培训/语言能力（注：带<font color="#ff6600">＊</font>号为必填项）</td>
  </tr>
  <tr>
    <td colspan="5">　　<b>请在“教育”栏目中填写您受过的正规教育；在“培训”栏目中填写接受过的各种培训，包括非正规教育，公司培训等等。按&quot;添加&quot;增加新的教育/培训经历。要修改或删除某项教育/培训经历，按此纪录后的&quot;编辑&quot;或&quot;删除&quot;。</b></td>
    </tr>
<tr>
<td align="right"><b>添加教育</b></td>
<td colspan="4">
<input type="checkbox" name="education" id="education" value="1" onClick="javascript:show('education','educationcon');" />
<span class="f00">选择此项添加教育</span>
<table width="100%" border="0" id="educationcon" style="display:none">
  <tr>
    <td width="80"><font color="#ff6600">　＊</font>时间：</td>
    <td>  从
<select name="edu_start_year" id="edu_start_year">
<option value="0" selected="selected">年</option>
<%
for i=year(date())-70 to year(date())
response.write "<option value="&i&">"&i&"</option>"
next
%>
</select>
<select name="edu_start_month" id="edu_start_month">
<option value="0" selected="selected">月</option>
<%
for i=1 to 12
response.write "<option value="&i&">"&i&"</option>"
next
%>
</select>
到
<select name="edu_end_year" id="edu_end_year">
<option value="0" selected="selected">年</option>
<%
for i=year(date())-70 to year(date())
response.write "<option value="&i&">"&i&"</option>"
next
%>
</select>
<select name="edu_end_month" id="edu_end_month">
<option value="0" selected="selected">月</option>
<%for i=1 to 12
response.write "<option value="&i&">"&i&"</option>"
next
%>
</select>
(后两项不填表示至今)</td>
  </tr>
  <tr>
    <td><font color="#ff6600">　＊</font>学校：</td>
    <td>
<INPUT name=edu_school id="edu_school" size=50 maxLength=50></td>
  </tr>
  <tr>
    <td><font color="#ff6600">　＊</font>专业：</td>
    <td>
<select name="mainprofession" size="1" id="mainprofession" onChange=GetProfession(this.options[this.selectedIndex].value)>
<option value="" selected>---请选择---</option>
<%
Set rs= Server.CreateObject("ADODB.RecordSet")
sql="select profession_id,profession_name from job_profession where profession_fid=0 order by profession_id"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("profession_id")&">"&rs("profession_name")&"</option>"
rs.movenext
loop
rs.close
%>
</select>
<span id="load400"></span><span id="cprofession">
<select name=subprofession id="subprofession">
<option value="" selected>---请选择---</option>
</select>
</span></td>
  </tr>
  <tr>
    <td><font color="#ff6600">　＊</font>学历：</td>
    <td>
<select name="edu_edu">
<option value="" selected="selected">---请选择---</option>
<%sql="select edu_id,edu_name from job_edu order by edu_id desc"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("edu_id")&">"&rs("edu_name")&"</option>"
rs.movenext
loop
rs.close
%>
</select>
</td>
  </tr>
  <tr>
    <td>专业描述：</td>
    <td>
<textarea name="edu_detail" cols="50" id="edu_detail" style="HEIGHT: 150px"></textarea>
</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td><font color=#993300>专业描述您可以填写您所学专业包括什么课程，您的毕业设计等等。</font></td>
  </tr>
</table>
</td>
</tr>
  <tr>
    <td colspan="5">&nbsp;</td>
    </tr>
  <tr>
    <td align="right"><b>添加培训</b></td>
    <td colspan="4"><input type="checkbox" name="train" id="train" value="1" onClick="javascript:show('train','traincon');" />
<span class="f00">选择此项添加培训</span><table width="100%" border="0" id="traincon" style="display:none">
  <tr>
    <td width="80"><font color="#ff6600">＊</font>培训时间：</td>
    <td>从
<select name="train_start_year" id="train_start_year">
<option value="0" selected="selected">年</option>
<%
for i=year(date())-70 to year(date())
 response.write "<option value='"&i&"'>"&i&"</option>"
next
%>
</select>
<select name="train_start_month" id="train_start_month">
<option value="0" selected="selected">月</option>
<%
for i=1 to 12
 response.write "<option value='"&i&"'>"&i&"</option>"
next
%>
</select>
到
<select name="train_end_year" id="train_end_year">
<option value="0" selected="selected">年</option>
<%
for i=year(date())-70 to year(date())
response.write "<option value='"&i&"'>"&i&"</option>"
next
%>
</select>
<select name="train_end_month" id="train_end_month">
<option value="0" selected="selected">月</option>
<%
for i=1 to 12
response.write "<option value='"&i&"'>"&i&"</option>"
next
%>
</select>
 (后两项不填表示至今)</td>
  </tr>
  <tr>
    <td><font color="#ff6600">＊</font>培训机构：</td>
    <td>
  <input name="train_train" id="train_train" size="50" maxlength="50" />
</td>
  </tr>
  <tr>
    <td> 　培训地点：</td>
    <td>
  <input name="train_address" id="train_address" size="50" maxlength="50" />
</td>
  </tr>
  <tr>
    <td><font color="#ff6600">＊</font>培训课程：</td>
    <td>
  <input name="train_course" id="train_course" size="50" maxlength="50" />
</td>
  </tr>
  <tr>
    <td>　获得证书：</td>
    <td>
  <font color="#993300">
  <input name="train_certificate" id="train_certificate" size="50" maxlength="50" />
  </font></td>
  </tr>
  <tr>
    <td> 　详细描述：</td>
    <td>
  <textarea name="train_detail" cols="50" rows="8" id="train_detail" style="HEIGHT: 150px"></textarea></td>
  </tr></table>
</td>
    </tr>
  <tr>
    <td colspan="5">&nbsp;</td>
    </tr>
  <tr>
    <td align="right"><b>添加语言</b></td>
    <td colspan="4"><input type="checkbox" name="lang" id="lang" value="1" onClick="javascript:show('lang','langcon');" />
      <span class="f00">选择此项添加语言 </span>      <table width="100%" border="0" id="langcon" style="display:none">
        <tr>
          <td class="f00"><font color="#ff6600">＊</font>外语语种：
            <select name="language" id="language">
              <option value=0 selected>---请选择---</option>
              <%Set rs= Server.CreateObject("ADODB.RecordSet")
sql="select foreign_id,foreign_name from job_foreignlanguage"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("foreign_id")&">"&rs("foreign_name")&"</option>"
rs.movenext
loop
rs.close
%>
            </select>
            <font color="#ff6600">＊</font>掌握程度：
            <select name="master" id="select5">
              <option value=0 selected>---请选择---</option>
              <%
sql="select degree_id,degree_name from job_foreigndegree"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("degree_id")&">"&rs("degree_name")&"</option>"
rs.movenext
loop
rs.close
%>
            </select>
            </td>
          </tr>
</table></td>
    </tr>
  <tr>
    <td height="21" colspan="5" valign="middle"> 　工作经历（注：带<font color="#ff6600">＊</font>号为必填项）</td>
  </tr>
  <tr>
    <td colspan="5">　　<b>按"添加"增加新的工作经验。 要更改或删除某项工作经验，请按"编辑"或"删除"链接。</b></td>
  </tr>
  <tr>
    <td align="right"><b>添加经历</b></td>
    <td colspan="4"><input type="checkbox" name="work" id="work" value="1" onClick="javascript:show('work','workcon');" />
<span class="f00">选择此项添加经历</span><table width="100%" border="0" id="workcon" style="display:none">
  <tr>
    <td width="80"><font color="#ff6600">＊</font>时间范围：</td>
    <td>
  从
<select name="work_start_year" id="work_start_year">
<option value="0" selected="selected">年</option>
<%
for i=year(date())-70 to year(date())
 response.write "<option value='"&i&"'>"&i&"</option>"
next
%>
</select>
<select name="work_start_month" id="work_start_month">
<option value="0" selected="selected">月</option>
<%
for i=1 to 12
 response.write "<option value='"&i&"'>"&i&"</option>"
next
%>
</select>
到
<select name="work_end_year" id="work_end_year">
<option value="0" selected="selected">年</option>
<%
for i=year(date())-70 to year(date())
response.write "<option value='"&i&"'>"&i&"</option>"
next
%>
</select>
<select name="work_end_month" id="work_end_month">
<option value="0" selected="selected">月</option>
<%
for i=1 to 12
response.write "<option value='"&i&"'>"&i&"</option>"
next
%>
</select>
 (后两项不填表示至今)</td>
 </tr>
 <tr><td><font color="#ff6600">＊</font>公司名称：</td>
 <td>
  <input name=work_comname id="work_comname" size=50 maxLength=50>
</td>
 </tr>
 <tr><td><font color="#ff6600">＊</font>公司性质：</td>
 <td>
  <select name="work_ecoclass" size="1" id="select4">
<option value="" selected>---请选择---</option>
<%
Set rs= Server.CreateObject("ADODB.RecordSet")							
sql="select ecoclass_id,ecoclass_name from job_ecoclass"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("ecoclass_id")&">"&rs("ecoclass_name")&"</option>"
rs.movenext
loop
rs.close
%>
</select>
</td>
 </tr>
 <tr><td><font color="#ff6600">＊</font>所属行业：</td>
 <td>
  <select name=work_trade id="select2">
<option value="" selected>---请选择---</option>
<%
sql="select trade_id,trade_name from job_trade"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("trade_id")&">"&rs("trade_name")&"</option>"
rs.movenext
loop
rs.close
%>
</SELECT>
</td>
 </tr>
 <tr><td><font color="#ff6600">＊</font>所在部门：</td>
 <td>
  <INPUT name=work_dept id="work_dept" size=30 maxLength=25></td>
 </tr>
 <tr><td><font color="#ff6600">＊</font>岗位类别：</td>
 <td>
<select name="mainposition" size="1" id="mainposition" onChange=GetPosition(this.options[this.selectedIndex].value)>
<option value="" selected>---请选择---</option>
<%
sql="select position_id,position_name from job_position where position_fid=0"
rs.open sql,conn,1,1
do while not rs.eof
response.write"<OPTION value="&rs("position_id")&">"&rs("position_name")&"</option>"
rs.movenext
loop
rs.close
%>
</select>
<span id="load300"></span><span id="cposition">
<select name=subposition id="subposition">
<option value="" selected>---请选择---</option>
</select>
                </span></td>
 </tr>
 <tr><td><font color="#ff6600">＊</font>职位名称：</td>
 <td>
  <INPUT name=work_place id="work_place" size="30" maxLength=50></td>
 </tr>
 <tr><td><font color="#ff6600">　</font>工作描述：</td>
 <td>
  <TEXTAREA name=work_introduce cols=50 id="work_introduce" style="HEIGHT: 100px"></TEXTAREA></td>
 </tr>
 <tr><td></td>
 <td><FONT color=#ff6600>工作描述限2000个字符，请详细描述您的职责范围、工作任务以及取得的成绩等。 </FONT></td>
 </tr>
 <tr><td><font color="#ff6600">　</font>离职原因：</td>
 <td>
  <INPUT name=work_leftreason id="work_leftreason" size="28" maxLength=50></td>
 </tr>
 <tr><td></td>
 <td><FONT color=#ff6600>简明扼要地阐述离职原因，字数在50字以内。</FONT></td></tr></table></td>
    </tr>
      <tr>
    <td colspan="5" class="tdcolor">求职意向（注：带<font color="#ff6600">＊</font>号为必填项）</td>
  </tr>
  <tr>
    <td width="129" align="right">希望职位类别：</td>
    <td colspan="4">
<input type="radio" value="1" name="type" checked />全职
<input type="radio" value="2" name="type" />兼职
<input type="radio" value="3" name="type" />全职、兼职均可	</td>
  </tr>
  <tr>
    <td align="right"><font color="#ff6600">＊</font>希望行业类别：</td>
    <td colspan="4"><input type="hidden" name="trade" id="trade" value="" ><input name="trades" type="text" onClick="JumpSearchLayer(4,'personform','trade','trades');" size="60" readonly /></td>
  </tr>
  <tr>
    <td align="right"><font color="#ff6600">＊</font>希望岗位类别：</td>
    <td colspan="4"><input type="hidden" name="position" id="position" value="" ><input name="positions" type="text" onClick="JumpSearchLayer(1,'personform','position','positions');" size="60" readonly /></td>
  </tr>
  <tr>
    <td align="right"><font color="#ff6600">＊</font>希望工作地区：</td>
    <td colspan="4">
	<!--调用三级地区-->
	<input name="workadd" type="hidden" id="workadd" value="" /><input name="workadds" type="text" onClick="JumpSearchLayer(5,'personform','workadd','workadds');" id="workadds" size="60" readonly />
	</td>
  </tr>
  <tr>
    <td align="right">月薪要求：</td>
    <td colspan="4">
	<INPUT name=pay id="pay" size=6 maxLength=6>
<select name="paytemp" onChange="pay.value=this.value">
        <option value="" selected>请选择薪资范围</option>
		<option value="800以下">800以下</option>
		<option value="800～1000">800～1000</option>
		<option value="1000～1200">1000～1200</option>
		<option value="1200～1500">1200～1500</option>
		<option value="1500～2000">1500～2000</option>
		<option value="2000～2500">2000～2500</option>
		<option value="2500～3000">2500～3000</option>
		<option value="3000～4000">3000～4000</option>
		<option value="4000～6000">4000～6000</option>
		<option value="6000～9000">6000～9000</option>
		<option value="9000～12000">9000～12000</option>
		<option value="12000～15000">12000～15000</option>
		<option value="15000～20000">15000～20000</option>
		<option value="20000以上">20000以上</option>
      </select>
元 注：0表示面议! &nbsp;&nbsp;&nbsp;&nbsp;
<input name="stay" type="checkbox" id="stay" value="1">
要求提供住宿</td>    
  </tr>
  <tr>
    <td align="right">到岗时间：</td>
    <td colspan="4">
<SELECT name=workdate id="workdate">
<OPTION value="0">随时</option>
<OPTION value="7">1周以内</option>
<OPTION value="14">2周以内</option>
<OPTION value="30">1个月内</option>
<OPTION value="60">1～3个月</option>
<OPTION value="90">3个月以后</OPTION>
</SELECT>	</td>
  </tr>
  <tr>
    <td colspan="5" class="tdcolor">&nbsp; 以下限2000个字符，请详细地填写，这有助于用人单位充分了解你。</td>
  </tr>
  <tr>
    <td align="right">其他要求：</td>
    <td colspan="4"><TEXTAREA class=FieldText id=request style="FONT-SIZE: 12px" name=request rows=10 cols=80></TEXTAREA></td>
  </tr>
  <tr>
    <td width="129" height="44">&nbsp;</td>
    <td colspan="4"><br><br><label>
      <input type="submit" name="Submit" value="确认添加" class="inputs" />
      <input type="button" name="Submit2" value="取消返回" class="inputs" onClick="javascript:history.back()" />
    </label><br><br></td>
  </tr>
  </form>
</table>
<script language = "JavaScript" src="../../Js/gettrade.js"></script>
<script language = "JavaScript" src="../../Js/getposition.js"></script>
<script language = "JavaScript" src="../../Js/GetProvince.js"></script>
<script language = "JavaScript" src="../../Js/getprofession.js"></script>
<script language="javascript" src="../../js/jobjss.js"></script>
<script language = "JavaScript">
function changeProvince(selvalue)
{
document.personform.hukoucapital.length=0; 
document.personform.hukoucity.length=0;
var selvalue=selvalue;	  
var j,d,mm;
d=0;
for(j=0;j<provincearray.length;j++) 
	{
		if(provincearray[j][1]==selvalue) 
		{
			if (d==0)
			{
			mm=provincearray[j][2];
			}
		var newOption2=new Option(provincearray[j][0],provincearray[j][2]);
		document.all.hukoucapital.add(newOption2);
		d=d+1;	
		}		
		if(provincearray[j][1]==mm) 
		{		
			var newOption3=new Option(provincearray[j][0],provincearray[j][2]);
			document.all.hukoucity.add(newOption3);
		}			
	}
}
function changeCity(selvalue)  
{ 
	document.personform.hukoucity.length=0;  
	var selvalue=selvalue;
	var j;
	for(j=0;j<provincearray.length;j++) 
	{
		if(provincearray[j][1]==selvalue) 
		{
			var newOption4=new Option(provincearray[j][0],provincearray[j][2]);
			document.all.hukoucity.add(newOption4);
		}
	}
}
function selectprovince() 
{ 
	var j;
	for(j=0;j<provincearray.length;j++) 
	{
		if(provincearray[j][1]==0) 
		{
			var newOption4=new Option(provincearray[j][0],provincearray[j][2]);
			document.all.hukouprovince.add(newOption4);
		}
	}
}


function changeProvinces(selvalue)
{
document.personform.city.length=0; 
document.personform.capital.length=0;
var selvalue=selvalue;	  
var j,d,mm;
d=0;
for(j=0;j<provincearray.length;j++) 
	{
		if(provincearray[j][1]==selvalue) 
		{
			if (d==0)
			{
			mm=provincearray[j][2];
			}
		var newOption2=new Option(provincearray[j][0],provincearray[j][2]);
		document.all.capital.add(newOption2);
		d=d+1;	
		}		
		if(provincearray[j][1]==mm) 
		{		
			var newOption3=new Option(provincearray[j][0],provincearray[j][2]);
			document.all.city.add(newOption3);
		}			
	}
}
function changeCitys(selvalue)  
{ 
	document.personform.city.length=0;  
	var selvalue=selvalue;
	var j;
	for(j=0;j<provincearray.length;j++) 
	{
		if(provincearray[j][1]==selvalue) 
		{
			var newOption4=new Option(provincearray[j][0],provincearray[j][2]);
			document.all.city.add(newOption4);
		}
	}
}

function selectprovinces() 
{ 
var j;
	for(j=0;j<provincearray.length;j++) 
	{
		if(provincearray[j][1]==0) 
		{
			var newOption4=new Option(provincearray[j][0],provincearray[j][2]);
			document.all.province.add(newOption4);
		}
	}
}
selectprovince();
selectprovinces();
</script>
<!--#include file="../inc/copy.asp" -->
<%End Sub%>
<%CloseConn%>
<%Function isletternumber(strng)
 isletternumber = false
 Dim regEx, Match ' Create variables.
 Set regEx = New RegExp   ' Create a regular expression object (stupid, huh?)
 regEx.Pattern = "^[A-Za-z0-9]{4,20}$" ' Sets pattern.
 regEx.IgnoreCase = True   ' Set case insensitivity.
 Set Match = regEx.Execute(strng)   ' Execute search.
 if match.count then isletternumber= true
End Function
Sub SaveAddone()
member_login=trim(request("login"))
if not isletternumber(member_login) then
  Response.Write ("<script language=JavaScript>{alert('错误：用户名要求为4-20个字母或数字！请重新选择用户名。');location.href = 'javascript:history.go(-1)';}</script>")
  Response.End 
end if
set rs=server.createobject("ADODB.Recordset")
sql="select member_login from JOB_member where member_login='"&member_login&"'"
rs.open sql,conn,1,1
if not rs.eof then
 rs.close
 set rs=nothing
 Response.Write ("<script language=JavaScript>{alert('错误：用户名"&member_login&"已经存在！请选择新的用户名。');location.href = 'javascript:history.go(-1)';}</script>")
 Response.End
end if
rs.close
member_pwd=MD5(trim(Request("pwd")),32)
Member_apipwd=trim(Request("pwd"))
member_type=trim(Request("user_type"))
member_startdate=trim(Request("startdate"))
member_enddate=trim(Request("enddate"))
resume_name=CheckStr(trim(request("names")))
if resume_name="" then
 Response.Write ("<script language=JavaScript>{alert('错误：姓名不能为空!');location.href = 'javascript:history.go(-1)';}</script>")
 Response.End
end if
resume_sex=cint(trim(request("sex")))
resume_birth=cdate(request("birth"))
resume_cardtype=cint(trim(request("cardtype")))
resume_idcard=CheckStr(trim(request("idcard")))
if trim(request("nation"))<>"" then
 resume_nation=cint(trim(request("nation")))
end if
if trim(request("polity"))<>"" then
 resume_polity=cint(trim(request("polity")))
end if
if trim(request("marriage"))<>"" then
 resume_marriage=cint(trim(request("marriage")))
end if
if trim(request("height"))<>"" then
 resume_height=cint(trim(request("height")))
end if
if trim(request("weight"))<>"" then
 resume_weight=cint(trim(request("weight")))
end if
if trim(request("hukouprovince"))<>"" then
 resume_hukouprovinceid=trim(request("hukouprovince"))
end if
if trim(request("hukoucapital"))<>"" then
 resume_hukoucapitalid=trim(request("hukoucapital"))
end if
if trim(request("hukoucity"))<>"" then
 resume_hukoucityid=trim(request("hukoucity"))
end if
resume_provinceid=trim(request("province"))
resume_capitalid=trim(request("capital"))
resume_cityid=trim(request("city"))
If IsNumeric(resume_cityid)=False Then
 Response.Write ("<script language=JavaScript>{alert('目前所在地必须全部选择！');location.href = 'javascript:history.go(-1)';}</script>")
 Response.End
End If
resume_edu=cint(trim(request("edu")))
resume_zhicheng=CheckStr(trim(request("zhicheng")))
member_logo=CheckStr(trim(request("member_logo")))
resume_school=CheckStr(trim(request("school")))
if request("graduate")<>"" then
resume_graduate=cdate(request("graduate"))
end if
if trim(request("tel"))<>"" then
	resume_tel=trim(request("tel"))
end if
if CheckStr(trim(request("mobile")))<>"" then
	resume_tel=resume_tel&","&CheckStr(trim(request("mobile")))
else
	resume_tel=resume_tel
end if
resume_mobile=trim(request("mobile"))
resume_chat=CheckStr(trim(request("chat")))
resume_email=CheckStr(trim(request("email")))
resume_url=CheckStr(trim(request("url")))
resume_address=CheckStr(trim(request("address")))
resume_post=CheckStr(trim(request("post")))
resume_sumup=CheckStr(trim(request("sumup")))
resume_title=CheckStr(trim(request("title")))
if resume_title="" then
 Response.Write ("<script language=JavaScript>{alert('添加的简历名称不能为空!');location.href = 'javascript:history.go(-1)';}</script>")
 Response.End
end if
set rs=server.createobject("ADODB.Recordset")
sql="select resume_title from job_p_resume where resume_title='"&resume_title&"' and resume_pmember='"&member_login&"'"
rs.open sql,conn,1,1
if not rs.eof then
 rs.close
 set rs=nothing
 Response.Write ("<script language=JavaScript>{alert('简历名称已存在！');location.href = 'javascript:history.go(-1)';}</script>")
 Response.End
end if
rs.close
set rs=nothing
resume_usergroup=cint(trim(request("usergroup")))
resume_appraise=CheckStrbox(request("appraise"))
If lenmix(resume_appraise)>=2000 Then 
response.write "<script language=javascript>alert('错误：自我评价太长了，要求不多于2000个字符!！');location.href='javascript:history.back()';</script>"
response.end 
end if
resume_jobtype=cint(trim(request("type")))
resume_trade=trim(request("trade"))
if left(resume_trade,2)="0*" then
resume_trade=Replace(resume_trade,"0*","")
end if
resume_position=trim(request("position"))
resume_workadd=trim(request("workadd"))
if request("pay")<>"" then
	if IsNumeric(trim(request("pay"))) then
	resume_pay=request("pay")
	else
		Select Case trim(request("pay"))
		case "800以下":resume_pay=1
		case "1800～1000":resume_pay=2
		case "1000～1200":resume_pay=3
		case "1200～1500":resume_pay=4
		case "1500～2000":resume_pay=5
		case "2000～2500":resume_pay=6
		case "2500～3000":resume_pay=7
		case "3000～4000":resume_pay=8
		case "4000～6000":resume_pay=9
		case "6000～9000":resume_pay=10
		case "9000～12000":resume_pay=11
		case "12000～15000":resume_pay=12
		case "15000～20000":resume_pay=13
		case "20000以上":resume_pay=14
		end select
	end if
end if
if trim(request("stay"))="1" then
 resume_stay=1 
end if
if trim(request("workdate"))<>"" then
 resume_workdate=cint(trim(request("workdate")))
end if
resume_request=CheckStrbox(request("request"))
if trim(Request("education"))="1" then
education_school=CheckStr(trim(request("edu_school")))
education_edu=cint(trim(request("edu_edu")))
if education_school="" then
 Response.Write ("<script language=JavaScript>{alert('错误：院校名称不能为空!');location.href = 'javascript:history.go(-1)';}</script>")
 Response.End
end if
education_detail=CheckStrbox(request("edu_detail"))
If lenmix(education_detail)>=8000 Then 
response.write "<script language=javascript>alert('错误：专业描述太长了，要求不多于8000个字符！');location.href='javascript:history.back()';</script>"
response.end 
end if

education_startyear=cint(trim(request("edu_start_year")))
education_startmonth=cint(trim(request("edu_start_month")))
education_endyear=cint(trim(request("edu_end_year")))
education_endmonth=cint(trim(request("edu_end_month")))
education_mainprofession=cint(trim(request("mainprofession")))
education_subprofession=cint(trim(request("subprofession")))
'判断时间时候正确
if education_endyear<>0 then
	if education_startyear=<education_endyear then
		if education_endmonth<>0 then
			if education_startyear=education_endyear and education_startmonth>education_endmonth then
			response.write "<script language=javascript>alert('错误：教育时间填写不正确！');location.href='javascript:history.back()';</script>"
			response.end 
			end if
		end if
	else
	response.write "<script language=javascript>alert('错误：教育时间填写不正确！');location.href='javascript:history.back()';</script>"
	response.end 
	end if
end if
end if
if trim(Request("train"))="1" then
train_train=CheckStr(trim(request("train_train")))
if train_train="" then
 Response.Write ("<script language=JavaScript>{alert('错误：培训机构不能为空!');location.href = 'javascript:history.go(-1)';}</script>")
 Response.End
end if
train_detail=CheckStrbox(request("train_detail"))
If lenmix(train_detail)>=8000 Then 
response.write "<script language=javascript>alert('错误：详细描述太长了，要求不多于8000个字符!！');location.href='javascript:history.back()';</script>"
response.end 
end if
train_startyear=cint(trim(request("train_start_year")))
train_startmonth=cint(trim(request("train_start_month")))
train_endyear=cint(trim(request("train_end_year")))
train_endmonth=cint(trim(request("train_end_month")))
train_address=CheckStr(trim(request("train_address")))
train_course=CheckStr(trim(request("train_course")))
train_certificate=CheckStr(trim(request("train_certificate")))
'判断时间时候正确
if train_endyear<>0 then
	if train_startyear=<train_endyear then
		if train_endmonth<>0 then
			if train_startyear=train_endyear and train_startmonth>train_endmonth then
			response.write "<script language=javascript>alert('错误：培训时间填写不正确！');location.href='javascript:history.back()';</script>"
			response.end 
			end if
		end if
	else
	response.write "<script language=javascript>alert('错误：培训时间填写不正确！');location.href='javascript:history.back()';</script>"
	response.end 
	end if
end if
end if
if trim(Request("lang"))="1" then
lang_name=cint(trim(request("language")))
lang_master=cint(trim(request("master")))
end if
if trim(Request("work"))="1" then
work_comname=CheckStr(trim(request("work_comname")))
if work_comname="" then
 Response.Write ("<script language=JavaScript>{alert('错误：公司名称不能为空!');location.href = 'javascript:history.go(-1)';}</script>")
 Response.End
end if
work_introduce=CheckStrbox(request("work_introduce"))
If lenmix(work_introduce)>=8000 Then 
response.write "<script language=javascript>alert('错误：工作描述太长了，要求不多于8000个字符!！');location.href='javascript:history.back()';</script>"
response.end 
end if

work_startyear=cint(trim(request("work_start_year")))
work_startmonth=cint(trim(request("work_start_month")))
work_endyear=cint(trim(request("work_end_year")))
work_endmonth=cint(trim(request("work_end_month")))
work_ecoclass=cint(trim(request("work_ecoclass")))
work_trade=cint(trim(request("work_trade")))
work_dept=CheckStr(trim(request("work_dept")))
work_mainposition=cint(trim(request("mainposition")))
work_subposition=cint(trim(request("subposition")))
work_place=CheckStr(trim(request("work_place")))
work_leftreason=CheckStr(trim(request("work_leftreason")))
'判断时间时候正确
if work_endyear<>0 then
	if work_startyear=<work_endyear then
		if work_endmonth<>0 then
			if work_startyear=work_endyear and work_startmonth>work_endmonth then
			response.write "<script language=javascript>alert('错误：工作时间填写不正确！');location.href='javascript:history.back()';</script>"
			response.end 
			end if
		end if
	else
	response.write "<script language=javascript>alert('错误：工作时间填写不正确！');location.href='javascript:history.back()';</script>"
	response.end 
	end if
end if
end if
'查询默认模板ID
set rs=conn.execute("select * from JOB_Template where ChannelID=1 and IsDefault="&FR_HR_True&" and IsDefaultInProject="&FR_HR_True&" and typeid=13")
if not rs.eof then
resume_template=rs("TemplateID")
end if
rs.close
set rs=nothing
'添加对整合接口的支持
If API_Enable Then
	'重置错误状态和信息
	FoundErr = False
	ErrMsg = ""
	set sMyXmlHTTP=server.createobject("MSXML2.ServerXMLHTTP")
	sMyXmlHTTP.setTimeouts API_Timeout, API_Timeout, API_Timeout * 6, API_Timeout * 6
	Dim intIndex
		For intIndex = 0 To UBound(ArrUrls)
		sMyXmlHTTP.open "POST",ArrUrls(intIndex),false
		sMyXmlHTTP.setRequestHeader "Content-Type", "text/xml; charset=gb2312"
		sMyXmlHTTP.Send "<root><appid>finereason</appid><action>reguser</action><syskey>"&MD5(member_login & API_SysKey, 16)&"</syskey><username>"&member_login&"</username><password>"&Member_apipwd&"</password><email>"&company_email&"</email><question>默认问题</question><answer>默认答案</answer><userip>"&trueIP&"</userip><jointime>"&Now()&"</jointime><userstatus>0</userstatus></root>"
		If sMyXmlHTTP.readyState = 4 And sMyXmlHTTP.Status = 200 Then
			Dim objRecXml
			Set objRecXml = Server.CreateObject("Microsoft.XMLDOM")
			objRecXml.Async = False
			objRecXml.Load (sMyXmlHTTP.ResponseXML)
			If objRecXml.documentElement.selectSingleNode("//status").Text <> "0" Then
				FoundErr = True
				ErrMsg = objRecXml.documentElement.selectSingleNode("//message").Text & " [APIError-API-" & intIndex & "]"
			End If
		End If
		If FoundErr Then
			call Show_Err()
			Exit For
		End If
		Next
End If

set rs=server.createobject("ADODB.Recordset")
sql="select * from JOB_member where member_login='"&member_login&"'"
rs.open sql,conn,1,3
if rs.eof then
rs.addnew
rs("member_login")=member_login
rs("member_pwd")=member_pwd
rs("Member_Auditing")=1
rs("Member_groupid")=member_type
rs("member_startdate")=member_startdate
rs("member_enddate")=member_enddate
rs("Member_name")=resume_name
rs("Member_sex")=resume_sex
rs("Member_birth")=resume_birth
rs("Member_cardtype")=resume_cardtype
rs("Member_idcard")=resume_idcard
rs("Member_marriage")=resume_marriage
rs("Member_polity")=resume_polity
rs("Member_hukouprovinceid")=resume_hukouprovinceid
rs("Member_hukoucapitalid")=resume_hukoucapitalid
rs("Member_hukoucityid")=resume_hukoucityid
rs("Member_provinceid")=resume_provinceid
rs("Member_capitalid")=resume_capitalid
rs("Member_cityid")=resume_cityid
rs("Member_edu")=resume_edu
rs("Member_tel")=resume_tel
rs("Member_chat")=resume_chat
rs("Member_url")=resume_url
rs("Member_address")=resume_address
rs("Member_post")=resume_post
rs("member_mobile")=resume_mobile
rs("member_mobileshowflag")=1
rs("member_email")=resume_email
rs("member_emailshowflag")=1
rs("member_url")=resume_url
rs("member_regdate")=now()
rs("member_logindate")=now()
rs("member_loginnum")=1
rs("member_typeid")=1
rs("member_flag")=1'不需要审核
rs("member_consumenums")=clng(request("consume"))
rs("Member_balance")=0
rs("Member_integral")=0
rs("member_command")=0
rs("member_commandstartdate")=null
rs("member_commandenddate")=null
if member_logo<>"" then rs("Member_logo")=member_logo
rs("Member_logoflag")=1
rs.update
rs.close
end if
'添加简历
set rs=server.createobject("ADODB.Recordset")
sql="select * from job_p_resume"
rs.open sql,conn,1,3
conn.Execute("Update JOB_member set Member_resumenums=Member_resumenums+1 where Member_login='"&member_login&"' and Member_typeid=1")
'增加积分
rs.addnew
rs("resume_visitnum")=1    '新加默认浏览次数为0
rs("resume_education")=1
rs("resume_train")=1
rs("resume_lang")=1
rs("resume_work")=1
rs("resume_careerwill")=1
rs("resume_pmember")=member_login
rs("resume_usergroup")=resume_usergroup
rs("resume_title")=resume_title
rs("resume_name")=resume_name
rs("resume_sex")=resume_sex
rs("resume_birth")=resume_birth
rs("resume_cardtype")=resume_cardtype
rs("resume_idcard")=resume_idcard
rs("resume_nation")=resume_nation
rs("resume_polity")=resume_polity
rs("resume_marriage")=resume_marriage
rs("resume_height")=resume_height
rs("resume_weight")=resume_weight
rs("resume_hukouprovinceid")=resume_hukouprovinceid
rs("resume_hukoucapitalid")=resume_hukoucapitalid
rs("resume_hukoucityid")=resume_hukoucityid
rs("resume_provinceid")=resume_provinceid
rs("resume_capitalid")=resume_capitalid
rs("resume_cityid")=resume_cityid
rs("resume_edu")=resume_edu
rs("resume_zhicheng")=resume_zhicheng
rs("resume_school")=resume_school
rs("resume_graduate")=resume_graduate
rs("resume_tel")=resume_tel
rs("resume_chat")=resume_chat
rs("resume_email")=resume_email
rs("resume_url")=resume_url
rs("resume_address")=resume_address
rs("resume_post")=resume_post
rs("resume_sumup")=resume_sumup
rs("resume_appraise")=resume_appraise
rs("resume_jobtype")=resume_jobtype
rs("resume_trade")=resume_trade
rs("resume_position")=resume_position
rs("resume_workadd")=resume_workadd
rs("resume_pay")=resume_pay
rs("resume_stay")=resume_stay
rs("resume_workdate")=resume_workdate
rs("resume_request")=resume_request
rs("resume_personinfo")=1
rs("resume_work")=1
rs("resume_lang")=1
rs("resume_train")=1
rs("resume_education")=1
rs("resume_careerwill")=1
rs("resume_announcedate")=now()
rs("resume_chinese")=1 
rs("resume_cnstatus")=1
rs("resume_openness")=0
if resume_template<>"" then
rs("resume_template")=resume_template
end if
if AdminResCheckReg=1 then '系统是否审核简历
	rs("resume_flag")=0
else
	if resume_usergroup=2 then  '高级简历未审核
		if rid="" then  '新建高级简历审核
			rs("resume_flag")=0
		end if
	else
		rs("resume_flag")=1
	end if
end if 
rs.update
rs.close
session(""&FRHRCMS&"resume_title")=resume_title
sql="select resume_id from job_p_resume where resume_title='"&resume_title&"' and resume_pmember='"&member_login&"'"
rs.open sql,conn,1,1
rid=rs("resume_id")
rs.close:set rs=nothing

if trim(Request("education"))="1" then
'添加教育记录
sql="select * from job_p_education"
set rs=server.CreateObject("adodb.recordset")
rs.open sql,conn,1,3
rs.addnew
rs("education_startyear")=education_startyear
rs("education_startmonth")=education_startmonth
rs("education_endyear")=education_endyear
rs("education_endmonth")=education_endmonth
rs("education_school")=education_school
rs("education_mainprofession")=education_mainprofession
rs("education_subprofession")=education_subprofession
rs("education_edu")=education_edu
rs("education_detail")=education_detail
rs("education_pmember")=pmember_login
rs("education_resumeid")=rid
rs("education_language")=lang
rs.update
rs.close:set rs=nothing
end if
if trim(Request("train"))="1" then
'添加培训记录
sql="select * from job_p_training"
set rs=server.CreateObject("adodb.recordset")
rs.open sql,conn,1,3
rs.addnew
rs("train_startyear")=train_startyear
rs("train_startmonth")=train_startmonth
rs("train_endyear")=train_endyear
rs("train_endmonth")=train_endmonth
rs("train_train")=train_train
rs("train_address")=train_address
rs("train_course")=train_course
rs("train_certificate")=train_certificate
rs("train_detail")=train_detail
rs("train_pmember")=pmember_login
rs("train_resumeid")=rid
rs.update
rs.close:set rs=nothing
end if
if trim(Request("lang"))="1" then
'添加语言记录
set rs=server.CreateObject("adodb.recordset")
sql="select * from job_p_lang"
rs.open sql,conn,1,3
rs.addnew
rs("lang_name")=lang_name
rs("lang_master")=lang_master
rs("lang_pmember")=pmember_login
rs("lang_resumeid")=rid
rs.update
rs.close:set rs=nothing
end if
if trim(Request("work"))="1" then
'添加工作经验记录
set rs=server.CreateObject("adodb.recordset")
sql="select * from job_p_work"
rs.open sql,conn,1,3
rs.addnew
rs("work_startyear")=work_startyear
rs("work_startmonth")=work_startmonth
rs("work_endyear")=work_endyear
rs("work_endmonth")=work_endmonth
rs("work_comname")=work_comname
rs("work_ecoclass")=work_ecoclass
rs("work_trade")=work_trade
rs("work_dept")=work_dept
rs("work_mainposition")=work_mainposition
rs("work_subposition")=work_subposition
rs("work_place")=work_place
rs("work_introduce")=work_introduce
rs("work_leftreason")=work_leftreason
rs("work_pmember")=pmember_login
rs("work_resumeid")=rid
rs.update
rs.close:set rs=nothing
end if
'更新静态页面
set rsuc=conn.execute("select UseCreateHTML from JOB_Channel where ChannelID=1")
	UseCreateHTML=rsuc("UseCreateHTML")
set rsuc=nothing
if  CreateHTML=1 and UseCreateHTML<>0 then
	Call PersonResumeContentHtml(rid) '生成简历页面
end if
CloseConn
response.write ("<script language=JavaScript>if (confirm('人才添加成功！继续添加人才信息')){location.href='person_addresume.asp'}else{location.href='pmember_searchlist.asp'}</script>")
response.end
End Sub
%>