当前位置:网站首页>PHP talent recruitment system development source code recruitment website source code secondary development
PHP talent recruitment system development source code recruitment website source code secondary development
2022-07-05 16:49:00 【withkai44】
Recruitment needs · Resume management · Advertisement release
Recruitment demand release , Resume intelligence analysis , User tracking
Support video interview , Job fair , The school recruit , Special recruitment and other scenarios
headhunters · train · Question answering system
For the middle and high-end, tap high-end talents , Training institutions release courses
Book courses online , Q & A enhances website interactivity and stickiness
PHP Talent recruitment system development Source code Recruitment website source code secondary development
Demonstration station :https://v2.ch2p.cn/

<?php
class index_controller extends common{
function index_action(){
if($this->uid!=""&&$this->username!=""){
if($_GET['type']=="out"){
$this->cookie->unset_cookie();
}else{
$this->ACT_msg($this->config['sy_weburl']."/member", " You are already logged in !");
}
}
if($_GET['backurl']=='1'){
$this->cookie->setCookie("backurl",$_SERVER['HTTP_REFERER'],time()+60);
}
if(!$_GET['usertype']){
$_GET['usertype'] = 1;
}
$this->yunset("cookie", $_COOKIE['checkurl']);
$this->yunset("usertype",(int)$_GET['usertype']);
$this->yunset("loginname",$_COOKIE['loginname']);
$this->yunset("referurl",$_SERVER['HTTP_REFERER']);
$this->seo("login");
$this->yun_tpl(array('index'));
}
// validate logon
function loginsave_action(){
$Member = $this->MODEL('userinfo');
$lData['username'] = $_POST['username'];
$lData['uid'] = $this->uid;
$lData['usertype'] = $this->usertype;
$lData['act_login'] = $_POST['act_login'];
$lData['num'] = $_POST['num'];
$lData['loginname'] = $_POST['loginname'];
$lData['password'] = $_POST['password'];
$lData['referurl'] = $_POST['referurl'];
$lData['authcode'] = $_POST['authcode'];
$return = $Member->userLogin($lData);
if($return['uclogin']){
$error = 2;
$return['msg'] = $return['uclogin'];
}else{
$error = 1;
}
if($return['errcode']==2){
$this->layer_msg($return['msg'],9,0,Url('register',array('c'=>'ident')),2,$error);
}else if($return['url']){
$this->layer_msg($return['msg'],9,0,$return['url'],2,$error);
}else{
$this->layer_msg($return['msg']);
}
}
// Login SMS verification code sending
function sendmsg_action()
{
$noticeM = $this->MODEL('notice');
$result = $noticeM->jycheck($_POST['code'],' Front desk login ');
if(!empty($result)){
$this->layer_msg($result['msg'], 9, 0, '', 2, $result['error']);
}
$moblie = $_POST['moblie'];
$UserinfoM = $this->MODEL('userinfo');
$userinfo = $UserinfoM->getInfo(array("moblie" => $moblie),array('field'=>"`usertype`,`uid`"));
$user = array(
'uid' => $userinfo['uid'],
'usertype' => $userinfo['usertype']
);
$result = $noticeM->sendCode($moblie, 'login', 1, $user, 6, 90, 'msg');
echo json_encode($result);exit();
}
function rest_action(){
$this->cookie->unset_cookie();
$url = Url("login",array("usertype"=>"1"),"1");
header("Location: ".$url);
}
function utype_action(){
if($this->uid){
header("Location:".$this->config['sy_weburl']."/member");
}
$this->seo("login");
$this->yun_tpl(array('utype'));
}
function setutype_action(){
// Verify the login data saved in the early stage , Whether it exists in this system and the password corresponds
if($_COOKIE['username'] && $_COOKIE['password'] && (CheckRegUser($_COOKIE['username']) OR CheckRegEmail($_COOKIE['username'])==false)){
// nothing usertype Under the circumstances To activate Otherwise, log in to the member center directly
$Member=$this->MODEL("userinfo");
$user = $Member->getInfo(array("username"=>$_COOKIE['username']),array("field"=>"`uid`,`username`,`password`,`salt`,`usertype,did`"));
$userid = $user['uid'];
if(!$user['usertype']){
if(passCheck($_COOKIE['password'],$user['salt'],$user['password']) && $user['password']!=''){
$usertype = (int)$_GET['usertype'];
if($usertype=='1'){
$table = "member_statis";
$table2 = "resume";
$data1=array("uid"=>$userid);
$data2['uid']=$userid;
}elseif($usertype=='2'){
$table = "company_statis";
$table2 = "company";
$ratingM = $this->MODEL('rating');
$data1 = $ratingM->FetchRatingInfo();
$data2['uid'] = $userid;
$data1['did'] = $user['did'];
}elseif($usertype=='3'){
$table = 'lt_statis';
$table2 = 'lt_info';
$id =$this->config['lt_rating'];
$row = $Member->GetRatinginfoOne(array('id'=>$id));
$data1=array('rating'=>$id,'integral'=>$this->config['integral_reg'],'rating_name'=>$row['name'],'rating_type'=>$row['type'],'lt_job_num'=>$row['lt_job_num'],'lt_down_resume'=>$row['lt_resume'],'lt_editjob_num'=>$row['lt_editjob_num'],'lt_breakjob_num'=>$row['lt_breakjob_num']);
if($row['service_time']>0){
$time=time()+86400*$row['service_time'];
}else{
$time=0;
}
$data1['vip_etime']=$time;
$data2['uid']=$userid;
$data2['did']=$user['did'];
}
$Member->upInfo(array(array("uid"=>$userid),"usertype"=>$usertype));
$Member->InsertReg($table,$data1);
$Member->InsertReg($table2,$data2);
$this->cookie->unset_cookie();
$this->cookie->add_cookie($userid,$user['username'],$user['salt'],$user['email'],$user['password'],$usertype,$this->config['sy_logintime'],$user['did']);
header("Location:".$this->config['sy_weburl'].'/member');
}else{
$this->cookie->unset_cookie();
echo " Activation failed ";
}
}else{
$this->cookie->unset_cookie();
echo " Activation failed ";
}
}else{
header("Location:".Url('index'));
}
}
// Wechat login
function wxlogin_action()
{
$wxloginid = isset($_COOKIE['wxloginid']) ? $_COOKIE['wxloginid'] : '';
$WxM = $this->MODEL('weixin');
$qrcode = $WxM->applyWxQrcode($wxloginid, '', $this->uid);
if (!$qrcode) {
echo 0;
} else {
echo $qrcode;
}
}



边栏推荐
猜你喜欢
随机推荐
Basic introduction to the control of the row component displaying its children in the horizontal array (tutorial includes source code)
Win11 prompt: what if the software cannot be downloaded safely? Win11 cannot download software safely
[深度学习][原创]让yolov6-0.1.0支持yolov5的txt读取数据集模式
Do sqlserver have any requirements for database performance when doing CDC
數據訪問 - EntityFramework集成
[js] 技巧 简化if 判空
Writing method of twig array merging
How to install MySQL
Explain in detail the functions and underlying implementation logic of the groups sets statement in SQL
Jarvis OJ simple network management protocol
Binary tree related OJ problems
Bs-xx-042 implementation of personnel management system based on SSM
Scratch colorful candied haws Electronic Society graphical programming scratch grade examination level 3 true questions and answers analysis June 2022
Cartoon: what is blue-green deployment?
[brush questions] effective Sudoku
How to set the WiFi password of the router on the computer
【刷题篇】鹅厂文化衫问题
Spring Festival Limited "forget trouble in the year of the ox" gift bag waiting for you to pick it up~
树莓派4b安装Pytorch1.11
[61dctf]fm







