<?php
$SQL = "SELECT * from USERS WHERE ID = '$_GET[id]'"; $result = @mysql_query( $SQL ); $row = @mysql_fetch_array( $result );
if (empty($row[ID])) $qt = insert; else $qt = update;
?> 
<FORM METHOD="post" ACTION="../library/query.php">
  <INPUT TYPE="hidden" NAME="controller" VALUE="USERS~<?php echo $qt; ?>~show_users~<?php echo $_GET[id]; ?>">
<table width="100%" cellpadding="0" cellspacing="0" border="0">
<tr> 
<td class="td3" colspan="2"><b> User Details</b> </td>
</tr>
<tr> 
<td class="td4"  width="50%"> Username</td>
<td class="td4"  width="50%"> 
<input type="text" name="USERNAME" class="textarea100" value="<?php echo $row[USERNAME]; ?>">
</td>
</tr>
<tr> 
<td class="td4"  width="50%"> Email Address</td>
<td class="td4"  width="50%"> 
<input type="text" name="EMAIL" class="textarea100" value="<?php echo $row[EMAIL]; ?>">
</td>
</tr>
<tr> 
<td class="td4"  width="50%"> Password</td>
<td class="td4"  width="50%"> 
<input type="text" name="PASSWORD" class="textarea100" value="<?php echo $row[PASSWORD]; ?>">
</td>
</tr>
<tr> 
<td class="td4">&nbsp;</td>
<td class="td4"> 
<input type="submit" name="Submit" value="Submit">
</td>
</tr>
</table>
  </FORM>
