Advertisement
Guest User

Untitled

a guest
May 5th, 2017
127
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 4.69 KB | None | 0 0
  1.   function drawRegistrationForm($errors = array()) {
  2.     ?>
  3.         <h1>New User Registration</h1>
  4.         <h3>Once registered, you must confirm your email address. All fields are required.</h3>
  5.         <form method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>?page=register&cmd=register" enctype="multipart/form-data">
  6.         <fieldset>
  7.           <?php echo hidden(); ?>
  8.           <p class="left">
  9.             <label for="firstname">First Name:</label>
  10.             <input type="text" name="firstname" id="firstname" value="<?php echo isset($_POST['firstname']) ? format($_POST['firstname']) : ""; ?>" /> <?php echo jqHelp("Enter your first name here."); ?>
  11.           </p>
  12.           <?php if(@$errors['firstname']) { ?><p class="error">Please enter your first name</p><?php } ?>
  13.  
  14.           <p class="right">
  15.             <label for="lastname">Last Name:</label>
  16.             <input type="text" name="lastname" id="lastname" value="<?php echo isset($_POST['lastname']) ? format($_POST['lastname']) : ""; ?>" /> <?php echo jqHelp("Enter your last name here."); ?>
  17.           </p>
  18.           <?php if(@$errors['lastname']) { ?><p class="error">Please enter your last name</p><?php } ?>
  19.  
  20.           <p class="left">
  21.             <label for="username">Username:</label>
  22.             <input type="text" name="username" id="username" value="<?php echo isset($_POST['username']) ? format($_POST['username']) : ""; ?>" /> <?php echo jqHelp("Enter your username here.<br /><br /><strong>Note:</strong> Not case-sensitive"); ?>
  23.           </p>
  24.           <?php if(@$errors['username']) { ?><p class="error">Please enter your username</p><?php } ?>
  25.  
  26.           <p class="right">
  27.             <label for="email">Email:</label>
  28.             <input type="text" name="email" id="email" value="<?php echo isset($_POST['email']) ? format($_POST['email']) : ""; ?>" /> <?php echo jqHelp("Enter your email address here."); ?>
  29.           </p>
  30.           <?php if(@$errors['email']) { ?><p class="error">Please enter a valid email</p><?php } ?>
  31.  
  32.           <p class="left">
  33.             <label for="password">Password:</label>
  34.             <input type="password" name="password" id="password" value="<?php echo isset($_POST['password']) ? format($_POST['password']) : ""; ?>" /> <?php echo jqHelp("Enter your password here.<br /><br /><strong>Note:</strong> Passwords are CaSe-sEnSiTiVe!"); ?>
  35.           </p>
  36.           <?php if(@$errors['password']) { ?><p class="error">Please enter your password</p><?php } ?>
  37.  
  38.           <p class="right">
  39.             <label for="confirm">Confirm:</label>
  40.             <input type="password" name="confirm" id="confirm" value="<?php echo isset($_POST['confirm']) ? format($_POST['confirm']) : ""; ?>" /> <?php echo jqHelp("Confirm your password here.<br /><br /><strong>Note:</strong> Passwords are CaSe-sEnSiTiVe!"); ?>
  41.           </p>
  42.           <?php if(@$errors['confirm'] == 1) { ?><p class="error">Please confirm your password</p><?php } elseif(@$errors['confirm'] == 2) { ?><p class="error">Your passwords do not match</p><?php } ?>
  43.  
  44.           <p class="left">
  45.             <label for="phone">Phone:</label>
  46.             <input type="text" name="phone" id="phone" value="<?php echo isset($_POST['phone']) ? format($_POST['phone']) : ""; ?>" /> <?php echo jqHelp("Enter your primary phone number here."); ?>
  47.           </p>
  48.           <?php if(@$errors['phone']) { ?><p class="error">Please enter your phone</p><?php } ?>
  49.  
  50.           <p class="right">
  51.             <label for="site">Site:</label>
  52.             <input type="text" name="site" id="site" value="<?php echo isset($_POST['site']) ? format($_POST['site']) : ""; ?>" /> <?php echo jqHelp("Enter your site address here."); ?>
  53.           </p>
  54.           <?php if(@$errors['site']) { ?><p class="error">Please enter your site url</p><?php } ?>
  55.  
  56.           <p class="left">
  57.             <label for="captcha">Captcha:</label>
  58.             <input type="text" name="captcha" id="captcha" value="" /> <?php echo jqHelp("Enter the captcha code seen below.<br /><br /><strong>Note:</strong> Click the captcha code for a new captcha."); ?>
  59.           </p>
  60.  
  61.           <p class="right">
  62.             <label for="captcha">&nbsp;</label>
  63.             <img src="captcha.php" alt="Captcha" title="Captcha" class="captcha" width="205" height="35" /> <?php echo jqHelp("Enter this captcha code above.<br /><br /><strong>Note:</strong> Click the captcha code for a new captcha."); ?>
  64.           </p>
  65.           <?php if(@$errors['captcha']) { ?><p class="error">Invalid Captcha code</p><?php } ?>
  66.  
  67.           <p class="left">
  68.             <label for="captcha">&nbsp;</label>
  69.             <input type="submit" value="Register" class="submit" />
  70.           </p>
  71.         </fieldset>
  72.         </form>
  73.     <?php
  74.   }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement