Location: PHPKode > projects > PHP Authentication using Uma > uma/admin/adduser.html.php
<form action="<?= $_SERVER['PHP_SELF'] ?>" method="post">
<input type="hidden" name="op" value="commituser">
<input type="hidden" name="formData[id]" value="<?= $su->get('id') ?>">
<table border="0" bgcolor="#ffffff" width="100%" cellpadding="3" cellspacing="0" class="bodytext1">			
<tr><th colspan="2" class="header"><?= $title ?></th></tr>
<tr><td colspan="2"><span class="infotext"><?= $msg; ?></span><br><br>

</td></tr>
<!-- Login information goes here -->
<tr><td class="bodytext">Username: </td><td><input type="text" value="<?= $su->get('username') ?>" size="20" maxlength="20" name="formData[username]"></td></tr>
<tr><td>Password: </td><td><input type="password" name="form_password" value="" size="20" maxlength="35"></td></tr>
  	<tr><td>Confirm Password: </td><td><input type="password" name="form_password_conf" value="" size="20" maxlength="35"></td></tr>
	<tr>
        	<td>Security Question: </td>
        	<td>
                	<select name="formData[passphrase_id]">
			<option value="">Select One</option>
	<? 	
        	// Builds the passphrase select options from the database
        	for ($i = 0, $j = count($passphrases); $i < $j; $i++) { echo $passphrases[$i]->get("id") . " -- " . $su->get("passphrase_id") . "<br>\n";?>
	      		<option <? if ($passphrases[$i]->get("id") == $su->get("passphrase_id")) { echo " selected "; } ?>value="<?= $passphrases[$i]->get("id") ?>"><?= $passphrases[$i]->get("passphrase") ?></option>				
	<? 	} ?> 
       			</select>
        	</td>
	</tr>
	<tr>
		<td>Your Answer: </td>
 		<td><input type="text" value="<?= stripslashes($su->get("passphraseanswer")); ?>" name="formData[passphraseanswer]" size="20" maxlength="50"></td>
	</tr>
 	<tr>
        	<td>Firstname: </td>
		<td><input type="text" size="20" maxlength="20" name="formData[firstname]" value="<?= $su->get("firstname") ?>"></td>
	</tr>
	<tr>
		<td>Lastname: </td>
      		<td><input type="text" size="20" maxlength="20" name="formData[lastname]" value="<?= $su->get("lastname") ?>"></td>
      	</tr>
      	<tr>
      		<td>Address 1: </td>
      		<td><input type="text" size="25" maxlength="50" name="formData[address1]" value="<?= $su->get("address1") ?>"></td>
       	</tr>
	<tr>
		<td>Address 2: </td>
		<td><input type="text" size="25" maxlength="50" name="formData[address2]" value="<?= $su->get("address2") ?>"></td>
       	</tr>
       	<tr>
 		<td>City: </td>
      		<td><input type="text" size="15" maxlength="25" name="formData[city]" value="<?= $su->get("city") ?>"></td>
      	 </tr>
	 <tr>
	 	<td>Region: </td>
		<td><select name="formData[region]">
		<option value="">Select One</option>
		<?	Utils::printRegionOptions($su->get("region"), FALSE); ?>
                </select>
		</td>
	 </tr>
	 <tr>
	 	<td>Country: </td>
		<td><input type="text" name="formData[country]" value="<?= $su->get("country") ?>" size="20" maxlength="20"></td>
       	</tr>
       	<tr>
       		<td>Zip Code: </td>
     		<td><input type="text" size="5" maxlength="5" name="formData[zip]" value="<?= $su->get("zip") ?>"></td>
	</tr>
	<tr>
		<td>Phone 1:</td>
	      	<td><input type="text" name="formData[phone1]" value="<?= $su->get("phone1") ?>" size="25" maxlength="20"></td>
       	</tr>
	<tr>
		<td>Mobile Phone:</td>
      		<td><input type="text" name="formData[mobilephone]" value="<?= $su->get("mobilephone") ?>" size="25" maxlength="20"></td>
       	</tr>
      	<tr>
	       	<td>Fax: </td>
      		<td><input type="text" name="formData[fax]" value="<?= $su->get("fax") ?>" size="25" maxlength="20"></td>
      	</tr>
       	<tr>
     		<td>E-mail: </td>
       		<td><input type="text" value="<?= $su->get("email") ?>" name="formData[email]" size="25" maxlength="65"></td>
	</tr>
	<tr><td colspan="2" align="center">
	    <table border="0" cellspacing="0" cellpadding="0" class="bodytext1" width="100%">
	    <tr><td class="bodytext1"><b><u><span class="header1">Services</span></u></b>&nbsp;&nbsp;&nbsp;<a href="<?= $_SERVER['PHP_SELF'] ?>?addservice=1">[Add Service]</a></td></tr>
	    <tr><td align="center">
	        <table border="0" cellspacing="0" cellpadding="5" class="bodytext1">
		<tr><td>Access</td><td>Name</td><td>Permission</td></tr>
		<?php 
		$newRow = TRUE;
		foreach ($services as $serv) {
		    if (@in_array($serv->get('id'), $userServiceIDS)) {
		        $checked = " checked";
	            } else {
		        $checked = "";
		    }
		?>
		    <tr><td><input type="checkbox" name="uservice[<?= $serv->get('id') ?>]" value="<?= $serv->get('id') ?>"<?= $checked ?>></td>
		    <td><?= $serv->get('name') ?></td>
		    <td><input type="text" maxlength="2" size="2" name="userviceperm[<?= $serv->get('id') ?>]" value="<?= $su->getPerm($serv) ?>"></td>
		    </tr>
		<?php 
		} ?>
		</table>
	    </td></tr>
	    </table>
	</td></tr>
      	<tr>
		<td colspan="2" align="right"><input type="submit" value="Save">&nbsp;<input type="reset" value="Reset"></td>	    	
	</tr>
</table>
</form>
Return current item: PHP Authentication using Uma