<?php 

@session_start();


	if($_SESSION['SECEXP'] !=''){

	}else{
		echo "Go And Fuck Your Self";die;
	}
	
  
      	if(isset($_REQUEST['btnEdit'])){
			$sqlD = 'DELETE FROM '.$DB->pre.'percentage';
			$DB->dbQuery($sqlD);
			
			 $sqlI = 'INSERT INTO '.$DB->pre.'percentage set per="'.$_REQUEST['per'].'",dateAdded="'.date('Y-m-d H:i:s').'"';
			$msg = '';
			if($DB->dbQuery($sqlI)){
				$msg = 'Percentage Added Successfully...';
			}
		}
	  
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- meta http-equiv="X-UA-Compatible" content="IE=11" -->
<!--[if IE 7]>
<link rel="stylesheet" type="text/css" href="<?php echo SITEURL?>/css/ie7.css">
<![endif]-->
<!--[if IE 8]>
<link rel="stylesheet" type="text/css" href="<?php echo SITEURL?>/css/ie7.css">
<![endif]-->
<link rel="stylesheet" type="text/css" href="<?php echo SITEURL?>/css/ie7.css">
<style>
td a {
	font-weight: bold;
}
</style>

</head>

<body>
<div class="container" style="background:#fff;" >
  <div class="menus">
    <ul style="">
      <?php echo innerAdminMenu()?>
    </ul>
  </div>
  <div class="row" >
    <div class="a-form" style="width: 450px; float: left; background:#fff;" >
      <form action="<?php echo SITEURL?>/percentage" id="frmAgent" name="frmAgent" method="GET"  autocomplete="off">
        <div class="container">
        <?php 
			$sqlP = 'SELECT per FROM '.$DB->pre.'percentage';
			$P = $DB->dbRow($sqlP);
		?>
          <table>
            <tr>
              <td>Win Percentage</td>
              <td>
                  <input id="per" name="per" value="<?php echo $P['per']?>" required>
                  
                </td>
            </tr>
            <tr>
              <td><button class="btn" type="submit" id="btnEdit" name="btnEdit" style="background-color:#6F0">Update </button></td>
            </tr>
          </table>
        </div>
      </form>
    
      <p><?php echo $msg;?></p>
    </div>
  </div>
</div>
</body>
</html>
