true, ]); $page = ($_GET['page']>0) ? $_GET['page'] : 1; $nextPage = $page+1; $db=db("DB_MASTER"); $_GET['condition'] = $_GET['condition'] ? $_GET['condition'] : 3;//默认全文 if($_GET['param']){ $sql = "select keyword from 597_keywords where pinyin='{$_GET['param']}'"; $keywordArr = $db->fetch_array($sql); //zy20230410 通过拼音获取职位类别的数据 if(!$keywordArr){ $PositionClass = new Position(); $keywordRow = $PositionClass->getPositionByPinyinDB($_GET['param']); if($keywordRow) $keywordArr['keyword'] = $keywordRow['position_name']; } } $_region = $domainClass->get_subregion_list($domainInfo['region_id']); $time=time(); $from = $_POST['from']?$_POST['from']:$_GET['from']; $act = $_POST['act']?$_POST['act']:$_GET['act']; if (!$from) $from=$_SERVER['HTTP_REFERER']; $industryClass=new industry(); $industrys=$industryClass->get_all(); $industry0 = $industryClass->get_subIndustry_list(0); if(!empty($industrys)){ foreach ($industrys as $k => $l) { if(!empty($l['subItems'])){ foreach($l['subItems'] as $kk => $ll){ $data['calling_id'] = $ll['calling_id']; $data['calling_name'] = $ll['calling_name']; $industrysArr[] = $data; } } } } $__joinSalary=array(0=>'工资',1=>'1500以下', 2=>'1500-2500', 3=>'2500-3500', 4=>'3500-5000', 5=>'5000-7000', 6=>'7000-9000', 7=>'9000-12000', 8=>'12000-15000', 9=>'15000以上'); $__reward=array('1'=>'五险','2'=>'住房公积金','3'=>'包吃','4'=>'包住','5'=>'周末双休','6'=>'单休','7'=>'大小周','8'=>'加班补助','9'=>'班车接送'); $__comSize=array(9=>'10人以下', 49=>'10~50人', 199=>'50~200人', 499=>'200~500人', 999=>'500~1000人', 1000=>'1000人以上',10000=>'10000人以上'); $__degree=array(10=>'小学', 20=>'初中', 30=>'高中', 40=>'中技/中专', 50=>'大专', 60=>'本科', 70=>'硕士', 80=>'博士', 90=>'博士后'); $__joinType=array(1=>'全职', 2=>'兼职', 5=>'实习', 6=>'应届校招'); $__jobWorkYear=array('98'=>'在校生','99'=>'应届生',100=>'1年以内', 2=>'1-3年', 3=>'3-5年', 4=>'5-10年', 5=>'10年以上'); $__updateStep=array(0=>'不限',1=>'一天内',2=>'两天内', 3=>'三天内', 5=>'五天内', 7=>'一周内', 14=>'两周内', 30=>'一个月内', 60=>'两个月内', 90=>'三个月内', 180=>'半年内'); /*$joinSalary=array(0=>'面议',1=>'1500以下', 2=>'1500-2500', 3=>'2500-3500', 4=>'3500-5000', 5=>'5000-7000', 6=>'7000-9000', 7=>'9000-12000', 8=>'12000-15000', 9=>'15000以上')); $joinType=array(1=>'全职', 2=>'兼职', 3=>'校园招聘', 4=>'暑假工', 5=>'实习'); $degree=array(0=>'不限',10=>'小学', 20=>'初中', 30=>'高中', 40=>'中技/中专', 50=>'大专', 60=>'本科', 70=>'硕士', 80=>'博士', 90=>'博士后'); $jobGender=array(0=>'不限', 1=>'男性', 2=>'女性'); $comType=array(0=>'不限',1=>'国有企业', 2=>'外商独资、外企办事处', 3=>'中外合资(合营、合作)', 4=>'民营、私营公司', 5=>'上市公司', 6=>'股份制企业', 7=>'集体企业', 8=>'乡镇企业', 9=>'行政机关', 10=>'社会团体、非盈利机构', 11=>'事业单位', 12=>'跨国企业(集团)', 13=>'其他'); $jobWorkYear=array(0=>'不限',1=>'一年以上', 2=>'二年以上', 3=>'三年以上', 4=>'四年以上', 5=>'五年以上', 10=>'十年以上', 15=>'十五年以上', 20=>'二十年以上', 30=>'三十年以上', 50=>'退休人员'); $comSize=array(0=>'不限',9=>'10人以下', 49=>'10~50人', 199=>'50~200人', 499=>'200~500人', 999=>'500~1000人', 1000=>'1000人以上'); $updateStep=array(0=>'不限',1=>'一天内',2=>'两天内', 3=>'三天内', 5=>'五天内', 7=>'一周内', 14=>'两周内', 30=>'一个月内', 60=>'两个月内', 90=>'三个月内', 180=>'半年内');*/ //当前url $url='//'.$_SERVER['HTTP_HOST']; $searchUrl = array(); //处理关键词 if($_GET['txtKeyWord']) $_GET['q']=$_GET['txtKeyWord']; $_GET['keyword']=!empty($keywordArr['keyword']) ? $keywordArr['keyword'] : $_GET['q']; unset($_GET['txtKeyWord']); $_GET['keyword']=str_replace('/', ' ', $_GET['keyword']); if ($_GET['keyword'] =='公司名称 职位名称'){ $_GET['keyword'] = ''; } //城市 if($cityid){ $thisCityId = $domainClass->get_this_city($cityid); $thisCityArrayList = $domainClass->get_region($thisCityId,'region_name_short'); } if(!$_GET['area']) $_GET['area']=$cityid; $_area=$_GET['area']; //合并区域 if($_GET['rm']){ $searchUrl['rm']=intval($_GET['rm']); $rmStr = $domainClass->get_rm($searchUrl['rm']); if ($rmStr){ $_GET['area']=$rmStr; } } if($_GET['area']){ if (!empty($rmStr)) $searchUrl['area']=$_GET['area']; $region_name=$domainClass->get_region($_GET['area'],"region_name_short"); $rmlist = $domainClass->get_rmid($_GET['area']); //合并区域name /* if(!empty($rmlist)){ foreach ($rmlist as $k => $l) { if($l['rmid']==$_GET['rm']){ $curRmName = $l['rmname']; } } } */ $areaNum = count(explode(',',$_GET['area'])); }else{ $_GET['area'] = 1; $region_name['region_name_short'] = ''; $cityid = 1; } if($_GET['area']==1){ $region_name['region_name_short'] = ''; $cityid = 1; $cityInfo['region_name_short'] = ''; } $areaArray = explode(',',$_GET['area']); $thisCityArray = $domainClass->get_this_city_list($cityid); //处理关键词的SEO if ($_GET['keyword']){ $searchUrl['q']=trim($_GET['keyword'] ?: ''); //搜索公司 $searchCompanyClass = new searchCompany(); $queryCompany['csName'] = $_GET['keyword']; $queryCompany['pp'] = 1; //$queryCompany['q'] = $_GET['keyword']; $queryCompany['licenceCheck'] = array(1,2); $queryCompany['areaId'] = ($_GET['area']>0) ? $_GET['area'] : ''; $queryCompany = array_filter($queryCompany); $searchCompany = $searchCompanyClass->search($queryCompany); $companyListCid = $searchCompany['matches'][0]['id']; if($companyListCid>0){ $companyClass = new company(); $companyListArray = $companyClass->get_company($companyListCid,'cname,csName,comIndustry,comType,comWorkers,logoUrl'); $companyListArray['comWorkers'] = $__comSize[$companyListArray['comWorkers']]; $companyListArray['comType'] = $__comProperty[$companyListArray['comType']]; $companyListArray['_cid'] = idEncode($companyListCid); $jobListArray=array_values($companyClass->get_joblist_array($companyListCid)); $companyListArray['jobNum'] = sys_count($jobListArray); $companyListArray['jname'] = $jobListArray[0]['jname']; } //获取相关职位 $sql="select other_keyword from 597_keywords where keyword = '".$_GET['keyword']."'"; $other_keyword=$db->fetch_first($sql); if ($other_keyword) $other_keyword=explode(',', $other_keyword); //搜索新数据 $keywordStr = trim($_GET['keyword']);//搜索词 $areaStr = trim($_GET['area']);//城市id $areaName = trim($region_name['region_name_short']);//城市名称; $searchDataStr = $keywordStr; //if($areaStr) { // $searchDataStr .= '|'.$areaStr; // $searchDataStr .= '|'.$areaName; //} $searchData = array(); //搜索历史数据整合 $tipHot8 = sys_getcookie('tipHot8'); if($tipHot8){ $tipHot8 = urldecode($tipHot8); $oldSearchData = explode('|||', $tipHot8); foreach ($oldSearchData as $key => $value) { $valArr = explode('|', $value); //if($valArr[0]==$keywordStr && $valArr[1]==$areaStr){ if($valArr[0]==$keywordStr){ //存在删除旧的 unset($oldSearchData[$key]); break; } } if(sys_count($oldSearchData)>=10) array_pop($oldSearchData);//最多10个 array_unshift($oldSearchData, $searchDataStr); $searchData = $oldSearchData; }else{ array_push($searchData, $searchDataStr); } // println($searchData); $searchDataStr = implode('|||', $searchData); sys_setcookie('tipHot8', urlencode($searchDataStr),0,COOKIE_PATH,ROOT_DOMAIN); } //附近职位 $_GET['comLatitude'] = $_GET['comLatitude'] ? $_GET['comLatitude'] : sys_getcookie('comLatitude'); $_GET['comLongitude'] = $_GET['comLongitude'] ? $_GET['comLongitude'] : sys_getcookie('comLongitude'); $geoAddress = $_GET['geoAddress'] ? $_GET['geoAddress']:sys_getcookie('geoAddress');//定位地址 if($_GET['distance']){ $distance = $_GET['distance']/1000; if($distance>=1){ $distance .= 'km'; }else{ $distance = $_GET['distance'].'m'; } $searchUrl['distance']=intval($_GET['distance']); } if($_GET['jobsort']){ $jobsortArr = explode(',', $_GET['jobsort']); if(sys_count($jobsortArr)==1){ $PositionClass = new Position(); $PositionArray = $PositionClass->getPositionById($_GET['jobsort']); $PositionArrayStr = $PositionArray['position_name']; } } if($_GET['callingId']){ $CallingExpect=intval($_GET['callingId']); $industryClass=new industry(); $Calling=$industryClass->get_industry($CallingExpect,'parent_id'); if($Calling['parent_id']==0){ $topCalling=$CallingExpect; }else{ $topCalling=$Calling['parent_id']; $bottomCalling=$CallingExpect; } $searchUrl['callingId']=$_GET['callingId']; } $industryClass=new industry(); $industryList=$industryClass->get_all(); $topRegion=$domainClass->get_subregion_list(1); if($_GET['selGender']){ $searchUrl['selGender']=intval($_GET['selGender']); } if($_GET['Reward']){ $_GET['Reward'] = $_GET['Reward']; $Reward=$_GET['Reward']; $searchUrl['Reward']=$_GET['Reward']; } switch ($_GET['selJoinSalary']){ case '1': $_GET['maxSalary']=1500; break; case '2': $_GET['minSalary']=1500; $_GET['maxSalary']=2500; break; case '3': $_GET['minSalary']=2500; $_GET['maxSalary']=3500; break; case '4': $_GET['minSalary']=3500; $_GET['maxSalary']=5000; break; case '5': $_GET['minSalary']=5000; $_GET['maxSalary']=7000; break; case '6': $_GET['minSalary']=7000; $_GET['maxSalary']=9000; break; case '7': $_GET['minSalary']=9000; $_GET['maxSalary']=12000; break; case '8': $_GET['minSalary']=12000; $_GET['maxSalary']=15000; break; case '9': $_GET['minSalary']=15000; break; default: break; } if($_GET['minSalary']||$_GET['maxSalary']){ $minSalary=intval($_GET['minSalary']); $maxSalary=intval($_GET['maxSalary']); $showSalary=$_GET['showSalary']; $searchUrl['minSalary']=intval($_GET['minSalary']); $searchUrl['maxSalary']=intval($_GET['maxSalary']); $searchUrl['selJoinSalary']=$_GET['selJoinSalary']; $_selJoinSalary=$__joinSalary[$showSalary]; } $showSalary=-1; if (!$minSalary&&!$maxSalary) $showSalary=0; if (!$minSalary&&$maxSalary==1500) $showSalary=1; if ($minSalary>=1500&&$maxSalary<=2500) $showSalary=2; if ($minSalary>=2500&&$maxSalary<=3500) $showSalary=3; if ($minSalary>=3500&&$maxSalary<=5000) $showSalary=4; if ($minSalary>=5000&&$maxSalary<=7000) $showSalary=5; if ($minSalary>=7000&&$maxSalary<=9000) $showSalary=6; if ($minSalary>=9000&&$maxSalary<=12000) $showSalary=7; if ($minSalary>=12000&&$maxSalary<=15000) $showSalary=8; if ($minSalary>=15000&&!$maxSalary) $showSalary=9; if($_GET['ComProperty']){ $ComProperty=intval($_GET['ComProperty']); $searchUrl['ComProperty']=intval($_GET['ComProperty']); } if($_GET['ComSize']){ $ComSize=$_GET['ComSize']; $searchUrl['ComSize']=intval($_GET['ComSize']); } if($_GET['Degree']){ $Degree=$_GET['Degree']; $searchUrl['Degree']=intval($_GET['Degree']); } if($_GET['WorkYear']){ $WorkYear=explode(',',$_GET['WorkYear']); $workYearArray = array(); foreach ($WorkYear as $k=>$l){ switch ($l){ case '2': array_push($workYearArray,'1','2','3'); break; case '3': array_push($workYearArray,'3','4','5'); break; case '4': array_push($workYearArray,'5','6','7','8','9'); break; case '5': array_push($workYearArray,'10'); break; default: array_push($workYearArray,$l); break; } } $_GET['workYearArray'] = $workYearArray; $searchUrl['WorkYear']=intval($_GET['WorkYear']); } if($_GET['joinType']){ $joinType=$_GET['joinType']; $searchUrl['joinType']=intval($_GET['joinType']); } //$_GET['order']=10; if(!$_GET['order']) $_GET['order'] = 1; $searchUrl['order']=intval($_GET['order']); if($_GET['condition']){ $searchUrl['condition']=intval($_GET['condition']); } function getUrl($field,$searchUrl){ $url=''; $field=explode(',', $field); if ($searchUrl && $field){ foreach ($searchUrl as $key => $value) { if (!in_array($key, $field)) $url.="&$key=$value"; } return $url; }else{ return $url; } } //认证 if($_GET['auth']){ $authArray = explode(',',$_GET['auth']); foreach ($authArray as $k=>$l){ if($l==1) $_GET['comType'][] = 1; if($l==2) $_GET['comType'][] = 2; if($l==3) $_GET['vipTime2'] = 1; if($l==5) $_GET['urgency'] = 1; } } $keywordUrl=getUrl('q',$searchUrl); $jobsortUrl=getUrl('jobsort',$searchUrl); $callingIdUrl=getUrl('callingId',$searchUrl); $areaUrl=getUrl('area',$searchUrl); $rewardUrl=getUrl('Reward',$searchUrl); $propertyUrl=getUrl('ComProperty',$searchUrl); $comsizeUrl=getUrl('ComSize',$searchUrl); $degreeUrl=getUrl('Degree',$searchUrl); $workyearUrl=getUrl('WorkYear',$searchUrl); $joinTypeUrl=getUrl('joinType',$searchUrl); $orderUrl=getUrl('order',$searchUrl); $salaryUrl=getUrl('minSalary,maxSalary',$searchUrl); $conditionUrl=getUrl('condition',$searchUrl); $rmUrl=getUrl('rm',$searchUrl); $distanceUrl=getUrl('distance',$searchUrl); //搜索器处理 /* $_seeker=$_GET['seeker']; unset($_GET['seeker']); $db=db("DB_MASTER"); if ($_seeker) { //保存为搜索器 if ($uid){ $seek['uid']=$uid; $seek['seekName']=$_seeker; $seek['seek']=serialize($query); $seek['updateTime']=$time; $sql=$db->sql_insert('597_per_seeker',$seek); $db->query($sql); $tipJs='$.anchorMsg("
职位搜索器已保存成功!
", { icon: "warning" });'; }else{ $tipJs='$.anchorMsg("未登陆,无法保存您的职位搜索器!
", { icon: "warning" });'; } }else{ //不保存 //通过搜索器重造$query数据 $seekId=$_GET['sid']; if ($seekId){ $sql='select seek from 597_per_seeker where sid='.$seekId; $m=$db->result_first($sql); unset($query); $query=unserialize($m); } } */ $searchJobClass=new searchJob(); //$searchJobClass=new searchJobGroup(); $pp=$_GET['pp']=30;//分页 $_GET['jobExtension']=1;//职位推广 $_GET['page'] = $page; $_GET = array_filter($_GET); $result=$searchJobClass->search($_GET); //println($_GET); preg_match_all("/([, +-])?[ ]*([a-zA-Z0-9\x{4e00}-\x{9fa5}]+)/u", $_GET['keyword'], $match); $words = $match[2] ? $match[2] : array(); //关键字高亮开始 if ($_GET['keyword'] && $result['matches']){ foreach ($result['matches'] as $key => $value) { foreach ($words as $k => $word) { $result['matches'][$key]['jname'] = str_ireplace($word, "" . $word . "", $result['matches'][$key]['jname']); $result['matches'][$key]['cname'] = str_ireplace($word, "" . $word . "", $result['matches'][$key]['cname']); $result['matches'][$key]['jobContent'] = str_ireplace($word, "" . $word . "", $result['matches'][$key]['jobContent']); } } } //关键字高亮结束 $total=$result['total_found']; if ($total>2000){ if ($total>=100000){ $_total='搜到 100000+个职位,为您筛选前 2000 个 '; }else{ $_total='搜索到 '.$total.' 个职位,为您筛选前 2000 个 '; } $total=2000; }else{ $_total='搜索到 '.$total.' 个 '; } $pagehtml=new page(array('total'=>$total,'perpage'=>$pp)); $showpage=$pagehtml->show(9); $totalPage = ceil($total/$pp); //title if($_GET['keyword']||$cityInfo['region_name_short']) $seoTitle = $cityInfo['region_name_short'].$_GET['keyword']; //{$cityInfo['region_name_short']}校园招聘-应届生求职招聘-597直聘{$seoTitle}招聘信息-597直聘 //{$cityInfo['region_name_short']}校园招聘,应届生求职招聘{$seoTitle}招聘信息网,{$seoTitle}招聘 //597直聘为应届生提供最新最全的{$cityInfo['region_name_short']}企业校园招聘、应届生求职招聘信息,为广大应届毕业生搭建求职平台,促进应届生就业.{$seoTitle}招聘信息网为您提供最新最全的{$seoTitle}招聘信息,帮您找到最适合您的工作,求职找工作就上597直聘,直接和老板聊. $seo_title="{$seoTitle}招聘_{$cityInfo['region_name_short']}招聘网最新招聘信息_597直聘{$cityInfo['region_name_short']}人才网"; $seo_keywords="{$seoTitle}招聘_{$cityInfo['region_name_short']}招聘网_{$cityInfo['region_name_short']}最新招聘信息"; $seo_description="{$seoTitle}招聘网为求职者提供大量真实有效的{$seoTitle}最新招聘信息,同时各大{$cityInfo['region_name_short']}公司可以发布最新职位信息。最好的{$cityInfo['region_name_short']}招聘信息就在{$cityInfo['region_name_short']}招聘网。"; if($jobclassName){ $seo_title = $cityInfo['region_name_short'].$jobclassName."招聘_{$cityInfo['region_name_short']}招聘网最新招聘信息_597直聘{$cityInfo['region_name_short']}人才网"; $seo_keywords="{$seoTitle}招聘_{$cityInfo['region_name_short']}招聘网_{$cityInfo['region_name_short']}最新招聘信息"; $seo_description="{$seoTitle}招聘网为求职者提供大量真实有效的{$seoTitle}最新招聘信息,同时各大{$cityInfo['region_name_short']}公司可以发布最新职位信息。最好的{$cityInfo['region_name_short']}招聘信息就在{$cityInfo['region_name_short']}招聘网。"; } if($_GET['WorkYear']=='0,98,99'){ $seo_title="{$cityInfo['region_name_short']}校园招聘_{$cityInfo['region_name_short']}招聘网最新招聘信息_597直聘{$cityInfo['region_name_short']}人才网"; $seo_keywords="{$seoTitle}招聘_{$cityInfo['region_name_short']}招聘网_{$cityInfo['region_name_short']}最新招聘信息"; $seo_description="{$seoTitle}招聘网为求职者提供大量真实有效的{$seoTitle}最新招聘信息,同时各大{$cityInfo['region_name_short']}公司可以发布最新职位信息。最好的{$cityInfo['region_name_short']}招聘信息就在{$cityInfo['region_name_short']}招聘网。"; } if(strpos($_SERVER['HTTP_REFERER'],ROOT_DOMAIN)){ $originUrl = 1; } $showType = 1; //显示底部app下载 $showApp = 1; //用户行为埋点 $GLOBALS['userAnalysis']['apiPoint'][] = 'search_job'; $GLOBALS['userAnalysis']['apiKeyWord'] = $_GET["keyword"];//搜索推荐关键词 $GLOBALS['userAnalysis']['apiCity'] = explode(',', $_GET['area']);//搜索推荐城市,数组 $GLOBALS['userAnalysis']['apiJobs'] = $jobIds;//搜索推荐得到的职位,刷新的职位,数组 //打开微信打开app $wechat = new wechat(array('appid'=>$config['wechat']['appid'])); $wxdata['jsapi_ticket'] = $wechat->getJsApiTicket(); $wxdata['noncestr'] = substr(md5($time),0,10); $wxdata['timestamp'] = $time; $wxdata['url'] = 'https://m.'.ROOT_DOMAIN.$_SERVER['REQUEST_URI']; $signature = $wechat->getSignature($wxdata); $wechat_appid = $config['wechat']['appid']; if($_GET['showDownloadApp']==1){ include template('zhaopin/gongzhonghao'); }else{ include template('zhaopin/index'); } ?>