<link href="../css/reset.css" rel="stylesheet" type="text/css" media="all"/>
<link href="../css/all.css" rel="stylesheet" type="text/css" media="all"/>
<link  href="../css/plugins.css" rel="stylesheet" type="text/css" media="screen" />
<!--[if lt IE 7]><link rel="stylesheet" type="text/css" href="http://www.metin2.ro/css/ie6.css" media="screen"/><![endif]-->
<!--[if gte IE 6]><link rel="stylesheet" type="text/css" href="http://www.metin2.ro/css/ie7.css" media="screen"/><![endif]-->
<script type="text/javascript" src="../js/jquery-latest.pack.js"></script>
<script type="text/javascript" src="../js/jquery.validationEngine.modified.js"></script>
<script type="text/javascript" src="../js/jquery.validationEngine.rules.html"></script>
<script type="text/javascript" src="../js/iepngfix_tilebg.js"></script>
<script type="text/javascript" src="../js/jquery.tools.min.js"></script>
<script type="text/javascript" src="../js/jquery.fancybox-1.3.1.pack.js"></script>
<script type="text/javascript" src="../js/jquery.bgiframe.js"></script>
<script type="text/javascript" src="../js/main.js"></script>
<div id="register" class="col-2">
	<div class="content content-last">
		<div class="content-bg">
			<div class="content-bg-bottom">
				<h2><?PHP echo $serverSettings['titel']; ?> - Activarea contului</h2>
				<div id="progressTracker">
					<div id="progress1" class="inactive">
						<div class="step">1</div>
						<p class="progress-text">&#206;nregistreaz&#259;-te</p>
					</div>
					<div id="progress2" class="active">
						<div class="step">2</div>
						<p class="progress-text">Activeaz&#259; &#351;i descarc&#259;</p>
					</div>
					<div id="progress3" class="inactive">
						<div class="step">3</div>
						<p class="progress-text">Instaleaz&#259; &#351;i joac&#259;-te</p>
					</div>
				</div>
				<div class="inner-form-border">
					<div class="inner-form-box">
	<h3><a id="toLogin" href="index.php?s=login" title="sau la autentificare">sau la autentificare</a>Activeaz&#259; cont</h3>
	 <div class="trenner"></div><br/><br/>
<?PHP
  if(isset($_GET['do']) && $_GET['do']=="active" && isset($_GET['hash']) && !empty($_GET['hash'])) {
    if(strlen($_GET['hash'])==32 && $_GET['hash']!=1 && checkAnum($_GET['hash'])) {
      $cmdHash = "SELECT id,web_aktiviert FROM account.account WHERE web_aktiviert='".$_GET['hash']."' AND web_aktiviert!='1' LIMIT 1;";
      $qryHash = mysql_query($cmdHash,$sqlServ);
      
      if(mysql_num_rows($qryHash)) {
      
        $getData = mysql_fetch_object($qryHash);
        $userUpdate = "UPDATE account.account SET web_aktiviert='activ',status='OK', status_cont='ACTIV' WHERE id='".$getData->id."' LIMIT 1;";
        $updateQry = mysql_query($userUpdate,$sqlServ);
        
        if($updateQry) {
          echo'<center><h1>Contul t&#259;u a fost activat cu succes.';
          echo'<meta http-equiv="refresh" content="3; URL=index.php?s=download_r"></h1><br/><br/> <div class="trenner"></div><br/></center>';
        }
        else {
          echo'<center><h1>Trimiterea a e&#351;uat&#259;. V&#259; rug&#259;m contacta&#355;i un admin!</h1><br/><br/> <div class="trenner"></div><br/></center>';
        }
        
      }
      else {
        echo'<center><h1>Nu se poate g&#259;si o intrare de potrivire. Activarea a e&#351;uat.</h1><br/><br/> <div class="trenner"></div><br/></center>';
      }
      
    }
    else {
      echo'<center><h1>Nici un ha&#351; valid!</h1><br/><br/> <div class="trenner"></div><br/></center>';
    }
  }
?>

  						<p id="regLegend">* este necesar</p>
					</div>
				</div>
			</div>
		</div>
	</div>
</div>