| 氏 名 | ";
// name 1
$mailcontent .= " ".$_POST["name01"]." ".$_POST["name02"]."";
$mailcontent .= " |
| フリガナ | ";
// name 2
$mailcontent .= " ".$_POST["name03"]." ".$_POST["name04"]."";
$mailcontent .= " |
| 性別 | ";
// gender
$gender = $_POST["gender"]==1?"男":"女";
$mailcontent .= " ".$gender."";
$mailcontent .= " |
| 生年月日 | ";
// birthday
$mailcontent .= " 19".$_POST["y_1"]."年".$_POST["m_1"]."月".$_POST["d_1"]."日";
$mailcontent .= " |
| メールアドレス | ";
// mail 1
$mailcontent .= " ".$_POST["mail_1"]."@".$_POST["mail_2"]."";
$mailcontent .= " |
| 電話番号 | ";
// phone
$mailcontent .= " ".$_POST["phone"]."";
$mailcontent .= " |
| 希望日時 | ";
// hope time 1
$mailcontent .= " 第一希望 ".$_POST["m_2"]."月".$_POST["d_2"]."日 ".$_POST["t_2"]."時〜 ";
$mailcontent .= " 第一希望 ".$_POST["m_3"]."月".$_POST["d_3"]."日 ".$_POST["t_3"]."時〜";
$mailcontent .= " |
| 相談内容 | ";
// content
$mailcontent .= " ".$_POST["content"]."";
$mailcontent .= " |
| 相談方法 | ";
// type
if($_POST["type"] == "0"){
$mailcontent .= "弊社に直接訪問";
}
if($_POST["type"] == "1"){
$mailcontent .= "メールで相談";
}
if($_POST["type"] == "1"){
$mailcontent .= "電話で相談";
}
$mailcontent .= " |
";
$mailcontent .= " ";
$mailcontent .= " ";
require_once("./PHPMailer/class.phpmailer.php");
require_once("./PHPMailer/class.smtp.php");
date_default_timezone_set('UTC');
$attachment = $_FILES['attachment']['name'];
$path = $_FILES['attachment']['tmp_name'];
$mail=new PHPMailer();
$mail->CharSet="shift_jis";
$mail->IsSMTP();
$mail->Host="smtp.163.com";
$mail->SMTPAuth=true;
$mail->Username="public_t@163.com";
$mail->Password="qwer1234";
$mail->From="public_t@163.com";
$mail->FromName="job2me";
$mail->AddAddress("sales-jp@job2me.com");
//$mail->AddAddress("lean@job2me.com");
$mail->WordWrap=50;
if($path!='')
{$mail-> AddAttachment($path,$attachment);}
$mail->IsHTML(true);
$mail->Subject="Career Consulting Application";
$mail->Body=$mailcontent;
$mail->AltBody = "This is the text-only body";
if(!$mail->Send()&&is_file($path)){
print("");
}else{
print("");
print("");
}
}
}
?>