<?php session_start();
include("../includes/connection.php"); ?>
<?php include("../includes/func.php");
include("userPopup_inc.php"); ?>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Administrative Panel : Item</title>
<link href="includes/style.css" rel="stylesheet" type="text/css">
<script language="javascript" type="text/javascript">
	function validate(frm) {
		if (frm.email.value == "") {
			alert("Please enter email.");
			frm.email.focus();
			return (false);
		}
		
		return (true);
	}
</script>
</head>

<body>
<form name="frmCatPopup" method="post" onSubmit="return validate(this);">
<input type="hidden" name="user_id" value="<?php echo $_GET["user_id"]; ?>">
<table width="400" border="0" cellpadding="0" cellspacing="1" class="bgDarkGray">
    <tr>
        <td class="bgGray">&nbsp;</td>
    </tr>
    <tr>
        <td class="bgWhite"><table width="100%"  border="0">
            <tr align="center">
                <td colspan="2" class="note">&nbsp;<?php echo($errMsg); ?></td>
            </tr>
          
            <tr>
                <td width="38%" class="LabelBold">User First Name : </td>
                <td width="62%"><input type="text" size=20  name="first_name" value="<?php echo($rs["first_name"]); ?>"></td>
            </tr>
			<tr>
                <td width="38%" class="LabelBold">User Last Name : </td>
                <td width="62%"><input type="text" size=20  name="last_name" value="<?php echo($rs["last_name"]); ?>"></td>
            </tr>
			<tr>
                <td width="38%" class="LabelBold">User email : </td>
                <td width="62%"><input type="text" size=20  name="email" value="<?php echo($rs["email"]); ?>"></td>
            </tr>
			<tr>
                <td width="38%" class="LabelBold">User Login Id : </td>
                <td width="62%"><input type="text" size=20  name="user_name" value="<?php echo($rs["user_name"]); ?>"></td>
            </tr>
			<tr>
                <td width="38%" class="LabelBold">User Password : </td>
                <td width="62%"><input type="text" size=20  name="password" value="<?php echo($rs["password"]); ?>"></td>
            </tr>
			<?
				switch($rs["user_type"]){
					case 1:
						$user_type1="checked";
						break;
					case 2:
						$user_type2="checked";
						break;
					case 3:
						$user_type3="checked";
						break;
				}
			?>
            <tr>
                <td>&nbsp;</td>
                <td><input type="radio" name="user_type" value="1" <?=$user_type1?> >
                    <span class="LabelBold">Super Admin <br>
					<input type="radio" name="user_type" value="2" <?=$user_type2?>>
                    <span class="LabelBold">NewsLetter</span><br>
					<input type="radio" name="user_type" value="3" <?=$user_type3?>>
                    <span class="LabelBold">Customer</span>
					</td>
            </tr>
			
			  <tr>
                <td>&nbsp;</td>
                <td><input type="checkbox" name="active" value="1" <?php cbfx($rs["active"]); ?>>
                    <span class="LabelBold">Approved</span></td>
            </tr>
            <tr>
                <td colspan="2">&nbsp;</td>
            </tr>
        </table></td>
    </tr>
    <tr>
        <td align="right" class="bgGray"><input name="btnSave" type="submit" id="btnSave" value="Save">
        </td>
    </tr>
</table>
</form>
</body>
</html>
