"; } if($_POST["name1"] == "") { $mes .= "Your name Error! Please complete this field correctly.
"; } if($_POST["_from"] == "") { $mes .= "E-mail address Error! Please complete this field correctly.
"; } if($_POST["tel"] == "") { $mes .= "Phone number Error! Please complete this field correctly.
"; } if($_POST["zip"] == "") { $mes .= "Zip code Error! Please complete this field correctly.
"; } if($_POST["address"] == "") { $mes .= "Your address Error! Please complete this field correctly.
"; } if($_POST["comment"] == "") { $mes .= "Content Error! Please complete this field correctly.
"; } if($mes == "") { check(); exit; } else { view(1,$mes); exit; } } else { view(0,""); exit; } //index‰æ–Ê function view($opentype,$mes) { if($opentype == 1) { $action=$_POST["action"]; $name=$_POST["name"]; $name1=$_POST["name1"]; $from=$_POST["_from"]; $tel=$_POST["tel"]; $zip=$_POST["zip"]; $address=$_POST["address"]; $comment=$_POST["comment"]; } $comment=str_replace("\r","",$comment); $comment=str_replace("
","\n",$comment); mb_http_output("iso-8859-1"); print << TOTCHI

$mes


Inquiries or information

HOME > Inquiries or information

Inquires can be only e-mailed.

Dental clinic name*

Your name*

E-mail address*

Phone number*

Zip code*

Your address*

Content*


EOM; } function check() { $tomail=$_POST['_email']; $subject=$_POST['_subject']; $name=$_POST["name"]; $name1=$_POST["name1"]; $from=$_POST["_from"]; $tel=$_POST["tel"]; $zip=$_POST["zip"]; $address=$_POST["address"]; $comment=$_POST["comment"]; mb_http_output("iso-8859-1"); $comment=str_replace("\r","",$comment); $comment=str_replace("\n","
",$comment); print << TOTCHI

Inquiries or information

Contents confirmation screen

Dental clinic name
$name

Your name
$name1

E-mail address
$from

Phone number
$tel

Zip code:
$zip

Your address
$address

Content
$comment


EOM; } function send() { $tomail=$_POST["_email"]; $subject=$_POST["_subject"]; $name=$_POST['name']; $name1=$_POST['name1']; $from=$_POST['_from']; $tel=$_POST['tel']; $zip=$_POST['zip']; $address=$_POST["address"]; $comment=$_POST["comment"]; mb_language("En"); mb_internal_encoding("iso-8859-1"); mb_http_output("iso-8859-1"); $mailfrom="From:".mb_encode_mimeheader($name)."<".$from.">"; $comment=str_replace("\r","",$comment); $comment=str_replace("
","\n",$comment); $body="--".$subject."--\n\n"; $body.=" Dental Clinic Name - ".$_POST["name"]."\n"; $body.=" Name - ".$_POST["name1"]."\n"; $body.=" Tel - ".$_POST["tel"]."\n"; $body.=" Zip - ".$_POST["zip"]."\n"; $body.=" Address - ".$_POST["address"]."\n"; $body.=" Content - ".$comment."\n"; mb_send_mail($tomail,$subject,$body,$mailfrom); view(0,""); } ?>