<?php
include("global.inc.php");
$errors=0;
$error="The following errors occured while processing your form input.<ul>";
pt_register('POST','fullname');
pt_register('POST','emailAddress');
pt_register('POST','sendmessage');
$sendmessage=preg_replace("/(\015\012)|(\015)|(\012)/","&nbsp;<br />", $sendmessage);if($fullname=="" || $emailAddress=="" || $sendmessage=="" ){
$errors=1;
$error.="<li>You did not enter one or more of the required fields. Please go back and try again.";
}
if($errors==1) echo $error;
else{
$where_form_is="http".($HTTP_SERVER_VARS["HTTPS"]=="on"?"s":"")."://".$SERVER_NAME.strrev(strstr(strrev($PHP_SELF),"/"));
$message="full name: ".$fullname."
e mail Address: ".$emailAddress."
send message: ".$sendmessage."
";
$message = stripslashes($message);
mail("aiks_0822@yahoo.com.ph","Form Submitted at your website",$message,"From: phpFormGenerator");
?>


<!-- This is the content of the Thank you page, be careful while changing it -->

<h2>Thank you!</h2>

<table width=50%>
<tr><td>full name: </td><td> <?php echo $fullname; ?> </td></tr>
<tr><td>e mail Address: </td><td> <?php echo $emailAddress; ?> </td></tr>
<tr><td>send message: </td><td> <?php echo $sendmessage; ?> </td></tr>
</table>
<!-- Do not change anything below this line -->

<?php 
}
?>