|
|
|
@ -73,12 +73,13 @@ class Index extends CI_Controller {
|
|
|
|
|
|
|
|
|
|
//value邮件页面
|
|
|
|
|
public function mail_index(){
|
|
|
|
|
if($this->session->userdata('dingding_user_info') === false){
|
|
|
|
|
/*if($this->session->userdata('dingding_user_info') === false){
|
|
|
|
|
$this->load->view('login');
|
|
|
|
|
}else{
|
|
|
|
|
//print_r($this->session->userdata('dingding_user_info'));
|
|
|
|
|
$this->load->view('mail');
|
|
|
|
|
}
|
|
|
|
|
}*/
|
|
|
|
|
$this->load->view('mail');
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//发送邮件
|
|
|
|
@ -231,7 +232,7 @@ class Index extends CI_Controller {
|
|
|
|
|
|
|
|
|
|
$tolist_array = array();
|
|
|
|
|
$tolist_array['0'] = new stdClass();
|
|
|
|
|
$tolist_array['0']->ddu_Email = 'cyc@hainatravel.com';
|
|
|
|
|
$tolist_array['0']->ddu_Email = 'hr@chinahighlights.net';
|
|
|
|
|
|
|
|
|
|
if($this->do_sendmail('cyc',$tolist_array,'','应聘简历',$mailnody)){
|
|
|
|
|
echo '{"status":1}';
|
|
|
|
@ -575,6 +576,28 @@ class Index extends CI_Controller {
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public function upload_photos() {
|
|
|
|
|
$save_path = date('Y-m-d');
|
|
|
|
|
$jsfunction = 'get_photo_url';
|
|
|
|
|
$upload_id = 'Profile_file';
|
|
|
|
|
$config['upload_path'] = APPPATH . 'upload/' . $save_path;
|
|
|
|
|
if (!is_dir($config['upload_path'])) {
|
|
|
|
|
@mkdir($config['upload_path'], 0777, true);
|
|
|
|
|
}
|
|
|
|
|
$config['allowed_types'] = 'gif|jpg|png';
|
|
|
|
|
$config['encrypt_name'] = true;
|
|
|
|
|
|
|
|
|
|
$this->load->library('upload', $config);
|
|
|
|
|
if (!$this->upload->do_upload($upload_id)) {
|
|
|
|
|
$error = array('error' => $this->upload->display_errors());
|
|
|
|
|
var_dump($error);
|
|
|
|
|
} else {
|
|
|
|
|
$data = array('upload_data' => $this->upload->data());
|
|
|
|
|
$file_name = 'http://' . $_SERVER['HTTP_HOST'] . '/' . $config['upload_path'] . '/' . $data['upload_data']['file_name'];
|
|
|
|
|
echo "<script>parent.$jsfunction('$file_name');</script>";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//退出
|
|
|
|
|
public function logout(){
|
|
|
|
|
$this->session->unset_userdata('dingding_user_info');
|
|
|
|
|