?? resume.inc.php
字號:
<?php
/*********************/
/* */
/* Version : 5.1.0 */
/* Author : RM */
/* Comment : 071223 */
/* */
/*********************/
if ( !defined( "IN_UCHOME" ) )
{
exit( "Access Denied" );
}
$uid = empty( $_GET['uid'] ) ? $_SGLOBAL['supe_uid'] : intval( $_GET['uid'] );
$list = sqlforlist( "job_resumes", "uid=".$uid );
if ( empty( $list ) && empty( $_GET['op'] ) )
{
showmessage( "還沒有填寫個人簡歷", "job.php?ac=resume&op=edit" );
}
$list = $list[0];
if ( $list['hopesubindustry'] )
{
$list['hopesubindustry'] = unserialize( $list['hopesubindustry'] );
$list['hopesubindustry'] = implode( ",", $list['hopesubindustry'] );
}
if ( $list['hopesubposition'] )
{
$list['hopesubposition'] = unserialize( $list['hopesubposition'] );
$list['hopesubposition'] = implode( ",", $list['hopesubposition'] );
}
if ( !ckresume( $list ) )
{
showmessage( "由于 ".$list['name']." 的個人簡歷進行了隱私設置,你不能訪問當前內容!", "job.php", 3 );
}
$works = sqlforlist( "job_work", "uid=".$uid." ORDER BY beginyear DESC,beginmonth DESC" );
$studys = sqlforlist( "job_study", "uid=".$uid." ORDER BY beginyear DESC,beginmonth DESC" );
if ( $_POST )
{
foreach ( $GLOBALS['_POST'] as $key => $value )
{
$GLOBALS['_POST'][$key] = $key == "hopesubindustry" || $key == "hopesubposition" ? $value : trim( $value );
}
if ( $_POST['do'] == "add" )
{
if ( empty( $_POST['resumetitle'] ) )
{
showmessage( "教育程度為空,請返回。" );
}
else if ( empty( $_POST['name'] ) )
{
showmessage( "簡歷名稱為空,請返回。" );
}
else if ( empty( $_POST['email'] ) )
{
showmessage( "E-MAIL為空,請返回。" );
}
else if ( empty( $_POST['mophone'] ) )
{
showmessage( "手機為空,請返回。" );
}
else if ( empty( $_POST['edudegree'] ) )
{
showmessage( "教育程度為空,請返回。" );
}
else if ( empty( $_POST['hopejobtype'] ) )
{
showmessage( "工作類型為空,請返回。" );
}
$GLOBALS['_POST']['dateline'] = $_SGLOBAL['timestamp'];
$GLOBALS['_POST']['description'] = shtmlspecialchars( $_POST['description'] );
$GLOBALS['_POST']['customresume'] = checkhtml( $_POST['customresume'] );
$GLOBALS['_POST']['hopesubposition'] = serialize( $_POST['hopesubposition'] );
$GLOBALS['_POST']['hopesubindustry'] = serialize( $_POST['hopesubindustry'] );
unset( $_POST['do'] );
inserttable( "job_resumes", $_POST );
include_once( S_ROOT."./source/function_cp.php" );
$icon = "jobs";
$title_template = "{actor} 添加了自己的 <a href=\"job.php?ac=resume&uid=".$_POST['uid']."\"><b>個人簡歷</b></a>";
feed_add( $icon, $title_template );
showmessage( "添加成功", "job.php?ac=resume" );
}
else if ( $_POST['do'] == "update" )
{
unset( $_POST['do'] );
$GLOBALS['_POST']['description'] = shtmlspecialchars( $_POST['description'] );
$GLOBALS['_POST']['customresume'] = checkhtml( $_POST['customresume'] );
$GLOBALS['_POST']['hopesubindustry'] = array_unique( $_POST['hopesubindustry'] );
$GLOBALS['_POST']['hopesubposition'] = array_unique( $_POST['hopesubposition'] );
$GLOBALS['_POST']['hopesubposition'] = serialize( $_POST['hopesubposition'] );
$GLOBALS['_POST']['hopesubindustry'] = serialize( $_POST['hopesubindustry'] );
updatetable( "job_resumes", $_POST, array(
"uid" => $uid
) );
include_once( S_ROOT."./source/function_cp.php" );
$icon = "jobs";
$title_template = "{actor} 更新了自己的 <a href=\"job.php?ac=resume&uid=".$_POST['uid']."\"><b>個人簡歷</b></a>";
feed_add( $icon, $title_template );
showmessage( "更新成功", "job.php?ac=resume" );
}
}
$hasexperiencearr = array( " checked" );
$workstatushtml = "";
$workstatus = array( "暫時不想找工作", "目前正在找工作", "只有好的機會我才會考慮" );
foreach ( $workstatus as $key => $value )
{
$selectstr = $key == $list['workstatus'] ? " selected" : "";
$workstatushtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$sexarr = array( " checked" );
$marryarr = array( " selected" );
$hasoverseasarr = array( " checked" );
$birthyeayhtml = "";
$nowy = sgmdate( "Y" );
$i = 1;
for ( ; $i < 80; ++$i )
{
$they = $nowy - $i;
$selectstr = $they == $space['birthyear'] ? " selected" : "";
$birthyeayhtml .= "<option value=\"".$they."\"{$selectstr}>{$they}</option>";
}
$birthmonthhtml = "";
$i = 1;
for ( ; $i < 13; ++$i )
{
$selectstr = $i == $space['birthmonth'] ? " selected" : "";
$birthmonthhtml .= "<option value=\"".$i."\"{$selectstr}>{$i}</option>";
}
$birthdayhtml = "";
$i = 1;
for ( ; $i < 32; ++$i )
{
$selectstr = $i == $space['birthday'] ? " selected" : "";
$birthdayhtml .= "<option value=\"".$i."\"{$selectstr}>{$i}</option>";
}
$bloodhtml = "";
foreach ( array( "A", "B", "O", "AB" ) as $value )
{
$selectstr = $value == $space['blood'] ? " selected" : "";
$bloodhtml .= "<option value=\"".$value."\"{$selectstr}>{$value}</option>";
}
$resumestatushtml = "";
$resumestatus = array( "全站用戶可見", "全好友可見", "僅自己可見" );
foreach ( $resumestatus as $key => $value )
{
$selectstr = $key == $list['resumestatus'] ? " selected" : "";
$resumestatushtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$areahtml = "";
$areas = array( "其他", "中國大陸", "中國香港", "中國臺灣", "中國澳門", "東南亞", "歐洲", "南美", "非洲", "西亞", "北美", "美國", "英國", "法國", "德國", "日本", "韓國", "新加坡", "加拿大" );
foreach ( $areas as $key => $value )
{
$selectstr = $key == $list['area'] ? " selected" : "";
$areahtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$nationalityhtml = "";
$nationalitys = array( "其他", "漢族", "蒙古族", "彝族", "侗族", "哈薩克族", "畬族", "納西族", "仫佬族", "仡佬族", "怒族", "保安族", "鄂倫春族", "回族", "壯族", "瑤族", "傣族", "高山族", "景頗族", "羌族", "錫伯族", "烏孜別克族", "裕固族", "赫哲族", "藏族", "布依族", "白族", "黎族", "拉祜族", "柯爾克孜族", "布朗族", "阿昌族", "俄羅斯族", "京族", "門巴族", "維吾爾族", "朝鮮族", "土家族", "傈僳族", "水族", "土族", "撒拉族", "普米族", "鄂溫克族", "塔塔爾族", "珞巴族", "苗族", "滿族", "哈尼族", "佤族", "東鄉族", "達斡爾族", "毛南族", "塔吉克族", "德昂族", "獨龍族", "基諾族" );
foreach ( $nationalitys as $key => $value )
{
$selectstr = $key == $list['nationality'] ? " selected" : "";
$nationalityhtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$politicsstatushtml = "";
foreach ( array( "無", "群眾", "團員", "黨員", "民眾黨派", "其他" ) as $key => $value )
{
$selectstr = $key == $list['politicsstatus'] ? " selected" : "";
$politicsstatushtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$idcardtypehtml = "";
foreach ( array( "無", "身份證", "護照", "軍人證", "港澳身份證", "其他" ) as $key => $value )
{
$selectstr = $key == $list['idcardtype'] ? " selected" : "";
$idcardtypehtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$edudegreehtml = "";
$edudegrees = array( "無", "小學", "初中", "高中", "中技", "中專", "大專", "本科", "碩士", "MBA", "博士", "其他" );
foreach ( $edudegrees as $key => $value )
{
$selectstr = $key == $list['edudegree'] ? " selected" : "";
$edudegreehtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$emolumenttypehtml = "";
foreach ( array( "無", "人民幣", "港元", "美元", "日元", "歐元", "其他" ) as $key => $value )
{
$selectstr = $key == $list['emolumenttype'] ? " selected" : "";
$emolumenttypehtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$emolumenthtml = "";
$emoluments = array( "面議", "2萬以下/年", "2-3萬/年", "3-4萬/年", "4-5萬/年", "5-6萬/年", "8-10萬/年", "10-15萬/年", "15-30萬/年", "30-50萬/年", "50-100萬/年", "100萬以上/年" );
foreach ( $emoluments as $key => $value )
{
$selectstr = $key == $list['emolument'] ? " selected" : "";
$emolumenthtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$seniorityhtml = "";
foreach ( array( "無", "在校學生", "應屆畢業生", "一年以上", "二年以上", "三年以上", "五年以上", "八年以上", "十年以上" ) as $key => $value )
{
$selectstr = $key == $list['seniority'] ? " selected" : "";
$seniorityhtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$contacttypehtml = "";
foreach ( array( "無", "手機", "家庭電話", "工作電話", "電子郵件", "郵遞" ) as $key => $value )
{
$selectstr = $key == $list['contacttype'] ? " selected" : "";
$contacttypehtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$hopejobtypehtml = "";
$hopejobtypes = array( "無", "全職", "兼職", "臨時", "實習" );
foreach ( $hopejobtypes as $key => $value )
{
$selectstr = $key == $list['hopejobtype'] ? " selected" : "";
$hopejobtypehtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$languagehtml = "";
$languages = array( "無", "漢語", "英語", "日語", "法語", "俄語", "德語", "西班牙語", "朝鮮語", "阿拉伯語", "其他" );
foreach ( $languages as $key => $value )
{
$selectstr = $key == $list['language1'] ? " selected" : "";
$languagehtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$languagelevelhtml = "";
$languagelevels = array( "不限", "一般", "良好", "精通" );
foreach ( $languagelevels as $key => $value )
{
$selectstr = $key == $list['language1level'] ? " selected" : "";
$languagelevelhtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$language2html = "";
foreach ( $languages as $key => $value )
{
$selectstr = $key == $list['language2'] ? " selected" : "";
$language2html .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$language2levelhtml = "";
foreach ( $languagelevels as $key => $value )
{
$selectstr = $key == $list['language2level'] ? " selected" : "";
$language2levelhtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$language3html = "";
foreach ( $languages as $key => $value )
{
$selectstr = $key == $list['language3'] ? " selected" : "";
$language3html .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$language3levelhtml = "";
foreach ( $languagelevels as $key => $value )
{
$selectstr = $key == $list['language3level'] ? " selected" : "";
$language3levelhtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$hopeemolumenttypehtml = "";
$hopeemolumenttypes = array( "無", "人民幣", "港元", "美元", "日元", "歐元", "其他" );
foreach ( $hopeemolumenttypes as $key => $value )
{
$selectstr = $key == $list['hopeemolumenttype'] ? " selected" : "";
$hopeemolumenttypehtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$hopeemolumenthtml = "";
foreach ( $emoluments as $key => $value )
{
$selectstr = $key == $list['hopeemolument'] ? " selected" : "";
$hopeemolumenthtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
$entrytypehtml = "";
foreach ( array( "面議", "三天內", "一周內", "一個月內", "三個月內" ) as $key => $value )
{
$selectstr = $key == $list['entrytype'] ? " selected" : "";
$entrytypehtml .= "<option value=\"".$key."\"{$selectstr}>{$value}</option>";
}
?>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -