Effettuare una prenotazione!
Utilizzare le informazioni qui sotto per prenotare una camera.
Modulo di prenotazione |
if ($_POST)
{
$name=$_POST[name];
$email=$_POST[email];
$phone=$_POST[phone];
$intrare=$_POST[intrare];
$zile=$_POST[zile];
$tipcam=$_POST[tipcam];
if ( ($name!='') && ($tipcam!='') && ($intrare!='') && ($email!='') && ($phone!='') )
{
$trimis="Mesajul a fost trimis. Va multumim!";
$body1="Nume: $name
";
$body1.="Telefon: $phone
";
$body1.="Email: $email
";
$body1.="Intrare: $intrare
";
$body1.="Zile: $zile
";
$body1.="Tip Camera: >$tipcam
";
require_once('class.phpmailer.php');
$mail = new PHPMailer();
$mail->IsSMTP(); // telling the class to use SMTP
$mail->Host = "mail.regionalis.ro"; // SMTP server
$mail->SMTPDebug = 1; // enables SMTP debug information (for testing)
$mail->SMTPAuth = true; // enable SMTP authentication
$mail->Host = "mail.regionalis.ro"; // sets the SMTP server
$mail->Port = 26; // set the SMTP port for the GMAIL server
$mail->Username = "xpak+regionalis.ro"; // SMTP account username
$mail->Password = "deepdark"; // SMTP account password
$mail->SetFrom('contact@vigohotel.ro', 'Formular Rezervare Website VigoHotel.ro');
$mail->Subject = "Formular Rezervare Website $name";
$mail->MsgHTML($body1);
$address = 'reservation@vigohotel.ro';
$mail->AddAddress($address);
$mail->Send();
} else {
$trimis="Formularul nu este complet!";
};
};
?>