4 Replies Latest reply on Sep 1, 2008 10:03 AM by Newsgroup_User

    php web form confirmation page

    future-architect Level 1
      i have the following code for a register form, and was wondering how to get it to go to a confirmation/thank you page after the e-mail is sent to me. here is the code that i have so far:

      $ip = $_POST['ip'];
      $httpref = $_POST['httpref'];
      $httpagent = $_POST['httpagent'];
      $name = $_POST['name'];
      $email = $_POST['email'];
      $notes = $_POST['notes'];
      $password = $_POST['password'];
      $username = $_POST['username'];
      $ownemail = $_POST['ownemail'];
      $hear = $_POST['hear'];

      if (eregi('http:', $notes)) {
      die ("Do NOT try that");
      if(!$email == "" && (!strstr($email,"@") || !strstr($email,".")))
      echo "<h2>Use Back - Enter valid e-mail</h2>\n";
      $badinput = "<h2>Feedback was NOT submitted</h2>\n";
      echo $badinput;
      die ("Go back");

      if(empty($name) || empty($email) || empty($password )) {
      echo "<h2>Use Back - fill in all fields</h2>\n";
      die ("Use back");

      $todayis = date("l, F j, Y, g:i a") ;

      $password = $password ;
      $username = $username;

      $notes = stripcslashes($notes);

      $message = "Date Sent: $todayis [EST] \n
      From $name ($email)\n
      Username: $username \n
      Do they want their own e-mail address? $ownemail \n
      Password: $password \n
      How did they hear about us? $hear \n
      Additional Info: IP = $ip \n
      Browser Info: $httpagent \n

      $from = "From: $email\r\n";

      mail("myemail@hotmail.com", WebsiteMembershipRequest, $message, $from);

      <h2 align="center"><em>Congratulations!</em> We have received your membership account request</h2>
      <p align="center"> </p>
      <h3 align="center">Your account is almost ready!<br /></h3>
      <p><br />
      We now just need you to

      confirm your e-mail address that you registered with. A confirmation email has been sent to it. Please check your email and click the link to confirm your email address.</p>
      <h3>Having Trouble?</h3>
      <p>Be sure to check your spam or junk mail folders for the email. </p>
      <?php $notesout = str_replace("\r", "<br/>", $notes);
      echo $notesout; ?>

      <br />

      <a href="index.html">Continue...</a>