"); ${$form[$i]} = $_POST[$form[$i]]; } } // クリア if(!empty($_POST["reset"])) { for($z=0; $z < sizeof($form); $z++) { ${$form[$z]} = ""; } } // =========================================================================== // 入力チェック // =========================================================================== if(!empty($_POST["submit_1"])) { // 必須 for($i=0; $i"; } } } /* // 半角カナ for($i=0; $i"; } } } */ // メール if(!empty($mail)) { if(!preg_match("/^[-\w\.]+@[-\w\.]+$/i",$mail)) { $errormsg.= "We are sorry, your Email address seems to be incorrect.
"; } } // エラー回避 for($i=0; $i/", "", ${$form[$i]}); ${$form[$i]} = preg_replace("/
/", "", ${$form[$i]}); } } } // =========================================================================== // 送信処理 // =========================================================================== if(!empty($_POST["submit_2"])){ if(empty($error)) { for($i=0; $i/","",${$form[$i]}); ${$form[$i]} = preg_replace("/
/","",${$form[$i]}); ${$form[$i]} = htmlspecialchars_decode(${$form[$i]},ENT_QUOTES); } //------------------------------------------------- // カレントの言語・内部文字エンコーディングを設定 //------------------------------------------------- mb_language('Japanese'); mb_internal_encoding('UTF-8'); // 管理者へのメール $title = "【English】WEBサイトからのお問い合わせ"; $headers = "From:" . $mail; $msg1 = "WEBサイトから下記のお問い合わせがありました。\r\n\r\n"; $msg = "------------------------------------------\r\n\r\n"; $msg.= "[お名前] ".$name."\r\n\r\n"; $msg.= "[会社名] ".$company."\r\n\r\n"; $msg.= "[部署名] ".$division_name."\r\n\r\n"; $msg.= "[メールアドレス] ".$mail."\r\n\r\n"; $msg.= "[お電話番号] ".$tel."\r\n\r\n"; $msg.= "[お問い合わせ内容] \r\n".$comment."\r\n\r\n"; $msg.= "------------------------------------------\r\n\r\n"; $admin_msg = $msg1.$msg; // 送信者へのメール if($remail==1) { $msg_en = "------------------------------------------\r\n\r\n"; $msg_en.= "[Your name] ".$name."\r\n\r\n"; $msg_en.= "[Company Name] ".$company."\r\n\r\n"; $msg_en.= "[Department] ".$division_name."\r\n\r\n"; $msg_en.= "[E-mail Address] ".$mail."\r\n\r\n"; $msg_en.= "[Phone Number] ".$tel."\r\n\r\n"; $msg_en.= "[Inquiry] \r\n".$comment."\r\n\r\n"; $msg_en.= "------------------------------------------\r\n\r\n"; $reto = $mail; $title2 = "Thank you for contacting us."; $headers2 = "From:".$to; $msg2 = "Dear Customer\r\n\r\n"; $msg2.= "Thank you for contacting us. We are very pleased to answer your inquiry.\r\n\r\n"; $msg3.= "This mail was generated automatically.\r\n"; $msg3.= "Our staff will be in contact with you within three business days.\r\n"; $msg3.= "If you cannot receive our reply after a week, the E-mail address you entered might be incorrect.\r\n"; $msg3.= "Please be in contact with us again, thank you for your understanding.\r\n\r\n"; $msg3.= "******************************************\r\n"; $retrun_msg = $msg2.$msg_en.$msg3.$sign2; } $form_menu = "end"; // JISエンコード $admin_msg = mb_convert_encoding($admin_msg,"JIS"); $retrun_msg = mb_convert_encoding($retrun_msg,"JIS"); // 送信 if(mb_send_mail($to, $title, $admin_msg, $headers)) { if($remail==1) { mb_send_mail($reto, $title2, $retrun_msg, $headers2); } $form_menu = "end"; $success_comment = "Thank you very much.
Your inquiry has been sent succesfully.

"; $success_comment.= "Our staff will be in contact with you within three business days.
If you cannot receive our reply after a week, the E-mail address you entered might be incorrect.
"; $success_comment.= "Please be in contact with us again, thank you for your understanding.

"; } else { $success_comment = "Sorry, we can not send your inquiry.
"; $success_comment.= "Please be in contact with us again, thank you for your understanding.

"; } } } ?> Contact Us | T&T United Inc.
".$errormsg; } ?>

Please feel free to contact us anytime!

Required

Name
Company Name
Department
E-mail adress
Phone number
Message

 

"; } ?>

After confirmation, please click send button

Required

Name
Company Name
Department
E-mail address
Phone number
Message