Advertisement
Corey

Untitled

Mar 31st, 2011
258
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.78 KB | None | 0 0
  1. <?php
  2.     if ($DH_US->status == 'logged_in')
  3.     {
  4.         echo "You're logged in, there is no need for you to be accessing this webpage.";
  5.     }
  6.     else
  7.     {
  8.         if ($_POST)
  9.         {
  10.             $DH_US->register();
  11.             if ($DH_US->errors)
  12.             {
  13.                 foreach($DH_US->errors as $error)
  14.                     echo $error . "<br />";
  15.             }
  16.             else
  17.             {
  18.                 echo "Registration Complete";
  19.             }
  20.         }
  21.         else
  22.         {
  23.         ?>
  24.         <h2>Register</h2>
  25.         <form method='POST'>
  26.             <label for='DH_US_username'>Username:</label>
  27.             <input name='DH_US_username' type='input' />
  28.             <label for='DH_US_password'>Password:</label>
  29.             <input name='DH_US_password' type='password' />
  30.             <label for='DH_US_email'>E-Mail:</label>
  31.             <input name='DH_US_email' type='input' />
  32. <br />
  33.             <input type='submit' value='Register' />
  34.         </form>
  35.         <?php
  36.         }
  37.     }
  38. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement