<?php
  /**
   * Account Profile
   *
   * @package Digital Downloads Pro
   * @author wojoscripts.com
   * @copyright 2010
   * @version $Id: profile.php, v2.00 2011-07-10 10:12:05 gewa Exp $
   */
  define("_VALID_PHP", true);
  require_once("init.php");
  
  if (!$user->logged_in)
      redirect_to("index.php");
	  
  $row = $user->getUserData();
?>
<?php include("header.php");?>
  <h1><span><a href="account.php" class="button-alt-sml">دانـلــودهـای مـن</a></span>مـدیـریـت حسـاب کـاربـری شمـا&nbsp;&nbsp;</h1>
  <p class="info">...در اینجا شمـا می توانیـد مشخصـات حسـاب کـاربـری خود را تغییـر دهیـد</p>
  <div style="position:relative"> <span id="loader" style="display:none"></span>
    <div id="msgholder"></div>
  </div>
  <div class="box">
    <form action="" method="post" id="admin_form" name="admin_form">
      <table cellpadding="0" cellspacing="0" class="display">
        <thead>
          <tr>
            <th colspan="2" class="right">ویـرایـش حسـاب کـاربـری</th>
          </tr>
        </thead>
        <tfoot>
          <tr>
            <td colspan="2"><input name="doupdate" type="submit" value=" بـروز رسـانـی "  class="button"/></td>
          </tr>
        </tfoot>
        <tbody>
        <tr>
          <th width="200"><strong>نـام کـاربـری :</strong></th>
          <td><input name="username" type="text" disabled="disabled" class="inputbox" value="<?php echo $row['username'];?>" size="45" /></td>
        </tr>
        <tr>
          <th><strong>کـلـمه عبـور :</strong></th>
          <td><input name="password" type="password"  class="inputbox" size="45" />
            &nbsp;&nbsp; <?php echo tooltip('..آنـرا خـالـی بگـذاریـد، مگـر برای تغییـر کـلـمه عبـور');?></td>
        </tr>
        <tr>
          <th><strong>ایـمیـل : <?php echo required();?></strong></th>
          <td><input name="email" type="text" class="inputbox" value="<?php echo $row['email'];?>" size="45" maxlength="40" /></td>
        </tr>
        <tr>
          <th><strong>نـام :</strong> <?php echo required();?></th>
          <td><input name="fname" type="text" class="inputbox" value="<?php echo $row['fname'];?>" size="45" /></td>
        </tr>
        <tr>
          <th><strong>نـام خـانوادگـی :</strong> <?php echo required();?></th>
          <td><input name="lname" type="text" class="inputbox" value="<?php echo $row['lname'];?>" size="45" /></td>
        </tr>
        <tr>
          <th><strong>مشتـرک خبـرنـامـه :</strong></th>
          <td>بـلـه
            <input name="newsletter" type="radio" id="newsletter-1" value="1" <?php getChecked($row['active'], 1); ?>/>
            خـیـر
            <input name="newsletter" type="radio" id="newsletter-2" value="0" <?php getChecked($row['active'], 0); ?> /></td>
        </tr>
        <tr>
          <th><strong>تـاریـخ ثـبـت نـام :</strong></th>
          <td><span class="input-out"><?php echo $row['cdate'];?></span></td>
        </tr>
        <tr>
          <th><strong>آخـریـن ورود :</strong></th>
          <td><span class="input-out"><?php echo $row['ldate'];?></span></td>
        </tr>
        </tbody>
      </table>
    </form>
  </div>
<?php echo $core->doForm("processUser","ajax/controller.php");?>
<?php include("footer.php");?>