<?php
if (basename($_SERVER['SCRIPT_FILENAME']) == basename(__FILE__)){
echo "<p align=center><br><br><br><br><br><br><font size=\"6\" color=\"#FF0000\">ILLEGAL ACCESS !!";
echo "<meta http-equiv=\"refresh\" content=\"2; url=../index.php\">";
exit();} 
// // #-----------------------------------------------------------------------------#
// // #-------------------------------.*PRIMADESAIN*.-------------------------------#
// // #-------------------------------: Script MMM3 :-------------------------------#
// // #------------------- Copyright 2009-2015 Primadesain.com ---------------------#
// // #----------- Email: primapc57@gmail.com Phone: +62 852 2865 7360 -------------#
// // #--------- http://www.primadesain.com - http://www.primadesain.net -----------#
// // #-----------------------------------------------------------------------------#
// // #------------- Primadesain.Com | Jasa Webdesain Bisnis Online ----------------#
// // #--- Website Bisnis MLM, Bisnis Investasi, Forex, Hyip, Binary, Trinary, -----#
// // #------- Matrix 4 -- 10, Toko Online, Iklan Baris, Profil, Reseller. ---------#
// // #-----------------------------------------------------------------------------#
// // # This software is  furnished  under a  license and may  be used and   copied #
// // # only  in accordance with the terms of such  license and with  the inclusion #
// // # of  the above copyright notice.  This software or any other  copies thereof #
// // # may not be  provided or otherwise made available  to any other person.   No #
// // # title to and  ownership of the software is hereby transferred.              #
// // #                                                                             #
// // # You  may  not  reverse   engineer,  decompile,  defeat  license  encryption #
// // # mechanisms, or  disassemble  this  software  product  or software   product #
// // # license. We  may terminate  this license if you  don't comply  with any  of #
// // # the terms and   conditions set forth   in our  End  User  License Agreement #
// // # (EULA). In  such event, licensee  agrees to return licensor or  destroy all #
// // # copies of software upon termination  of the license.                        #
// // # Please see the EULA file for the full End User License Agreement.           #
// // ###############################################################################
?>
<style>
.ijo11 {
	-moz-box-shadow:inset 0px 1px 0px 0px #a4e271;
	-webkit-box-shadow:inset 0px 1px 0px 0px #a4e271;
	box-shadow:inset 0px 1px 0px 0px #a4e271;
	background:-webkit-gradient(linear, left top, left bottom, color-stop(0.05, #69BC25), color-stop(1, #44880D));
	background:-moz-linear-gradient(top, #69BC25 5%, #44880D 100%);
	background:-webkit-linear-gradient(top, #69BC25 5%, #44880D 100%);
	background:-o-linear-gradient(top, #69BC25 5%, #44880D 100%);
	background:-ms-linear-gradient(top, #69BC25 5%, #44880D 100%);
	background:linear-gradient(to bottom, #69BC25 5%, #44880D 100%);
	filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#69BC25', endColorstr='#44880D',GradientType=0);
	background-color:#77d42a;
	-moz-border-radius:3px;
	-webkit-border-radius:3px;
	border-radius:3px;
	border:1px solid #268a16;
	display:inline-block;
	cursor:pointer;
	color:#ffffff;
	font-family:arial;
	font-size:12px;
	font-weight:normal;
	padding:3px 10px;
	text-decoration:none;
	text-shadow:0px 1px 0px #528009;
}
.ijo11:hover {
	background:-webkit-gradient(linear, left top, left bottom, color-stop(0.05, #44880D), color-stop(1, #69BC25));
	background:-moz-linear-gradient(top, #44880D 5%, #69BC25 100%);
	background:-webkit-linear-gradient(top, #44880D 5%, #69BC25 100%);
	background:-o-linear-gradient(top, #44880D 5%, #69BC25 100%);
	background:-ms-linear-gradient(top, #44880D 5%, #69BC25 100%);
	background:linear-gradient(to bottom, #44880D 5%, #69BC25 100%);
	filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#5cb811', endColorstr='#77d42a',GradientType=0);
	background-color:#5cb811;
}
.ijo11:active {
	position:relative;
	top:1px;
}
.mmm_blue {
	-moz-box-shadow:inset 0px 1px 0px 0px #54a3f7;
	-webkit-box-shadow:inset 0px 1px 0px 0px #54a3f7;
	box-shadow:inset 0px 1px 0px 0px #54a3f7;
	background:-webkit-gradient(linear, left top, left bottom, color-stop(0.05, #007dc1), color-stop(1, #0061a7));
	background:-moz-linear-gradient(top, #007dc1 5%, #0061a7 100%);
	background:-webkit-linear-gradient(top, #007dc1 5%, #0061a7 100%);
	background:-o-linear-gradient(top, #007dc1 5%, #0061a7 100%);
	background:-ms-linear-gradient(top, #007dc1 5%, #0061a7 100%);
	background:linear-gradient(to bottom, #007dc1 5%, #0061a7 100%);
	filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#007dc1', endColorstr='#0061a7',GradientType=0);
	background-color:#007dc1;
	-moz-border-radius:3px;
	-webkit-border-radius:3px;
	border-radius:3px;
	border:1px solid #124d77;
	display:inline-block;
	cursor:pointer;
	color:#ffffff;
	font-family:arial;
	font-size:12px;
	font-weight:normal;
	padding:3px 7px;
	text-decoration:none;
	text-shadow:0px 1px 0px #154682;
}
.mmm_blue:hover {
	background:-webkit-gradient(linear, left top, left bottom, color-stop(0.05, #0061a7), color-stop(1, #007dc1));
	background:-moz-linear-gradient(top, #0061a7 5%, #007dc1 100%);
	background:-webkit-linear-gradient(top, #0061a7 5%, #007dc1 100%);
	background:-o-linear-gradient(top, #0061a7 5%, #007dc1 100%);
	background:-ms-linear-gradient(top, #0061a7 5%, #007dc1 100%);
	background:linear-gradient(to bottom, #0061a7 5%, #007dc1 100%);
	filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#0061a7', endColorstr='#007dc1',GradientType=0);
	background-color:#0061a7;
}
.mmm_blue:active {
	position:relative;
	top:1px;
}
</style>
<!-- BEGIN PAGE HEADER-->
			<h3 class="page-title">
			Reward <small>Reward</small>
			</h3>
			<div class="page-bar">
				<ul class="page-breadcrumb">
					<li>
						<i class="fa fa-home"></i>
						<a href="index.php">Home</a>
						<i class="fa fa-angle-right"></i>
					</li>
					<li>
						<a href="#">Reward</a>
						<i class="fa fa-angle-right"></i>
					</li>
					<li>
						<a href="#">Reward</a>
					</li>
				</ul>
				<div class="page-toolbar">
					
				</div>
			</div>
			<!-- END PAGE HEADER-->
   
<?php
if($db->dataku("status", $user_session) == 0 || $db->dataku("blokir", $user_session) == 1) {
echo "<div class='alert alert-danger alert-dismissable'><button type='button' class='close' data-dismiss='alert' aria-hidden='true'></button>".$LANG["status0"]."</div>";
}else{
?>
<!-- BEGIN PAGE CONTENT-->
<?php
 if(isset($_GET['result'])&&$_GET['result']=="no_pin"){
echo "<div class='alert alert-danger alert-dismissable'><button type='button' class='close' data-dismiss='alert' aria-hidden='true'></button>".LANG_FORGOT_NO_PIN."</div>";
}
?>  
 <?php
 if(isset($_GET['result'])&&$_GET['result']=="wrong_pin"){
echo "<div class='alert alert-danger alert-dismissable'><button type='button' class='close' data-dismiss='alert' aria-hidden='true'></button>".LANG_FORGOT_WRONG_PIN."</div>";
}
?>  
 <?php
 if(isset($_GET['result'])&&$_GET['result']=="pin_lock"){
echo "<div class='alert alert-danger alert-dismissable'><button type='button' class='close' data-dismiss='alert' aria-hidden='true'></button>".LANG_FORGOT_BLOCK_PIN."</div>";
}
?>  

 <?php
 if(isset($_GET['result'])&&$_GET['result']=="pin_off"){
echo "<div class='alert alert-danger alert-dismissable'><button type='button' class='close' data-dismiss='alert' aria-hidden='true'></button>".LANG_FORGOT_OFF_PIN."</div>";
}
?>
<?php
 if(isset($_GET['result'])&&$_GET['result']=="min_wd"){
echo "<div class='alert alert-danger alert-dismissable'><button type='button' class='close' data-dismiss='alert' aria-hidden='true'></button>Minimal WD is ".rupiah($bataswdnya1)."</div>";
}
?>
<?php
 if(isset($_GET['result'])&&$_GET['result']=="max_wd"){
echo "<div class='alert alert-danger alert-dismissable'><button type='button' class='close' data-dismiss='alert' aria-hidden='true'></button>Max WD is ".rupiah($bataswdnya2)."</div>";
}
?>
<?php
 if(isset($_GET['result'])&&$_GET['result']=="success"){
echo "<div class='alert alert-success alert-dismissable'><button type='button' class='close' data-dismiss='alert' aria-hidden='true'></button>Withdrawal reward telah dikirim, silahkan tunggu admin akan memproses reward anda.</div>";
}
?>
 
  <?



$rwww="SELECT peringkat2 FROM configuration"; 
$dtrwww=mysql_query($rwww);
$configrwww=mysql_fetch_array($dtrwww);
$batasrwd = explode("|", $configrwww['peringkat2']);
$rankrwd = explode("|", $configrwww['peringkat2']);
$rewardrwd = explode("|", $configrwww['peringkat2']);

$batasrwx1 = $batasrwd[0]; 
$batasrwx2 = $batasrwd[4]; 
$batasrwx3 = $batasrwd[8]; 
$batasrwx4 = $batasrwd[12]; 
$batasrwx5 = $batasrwd[16];
$batasrwx6 = $batasrwd[20];

$rankrwx1 = $rankrwd[1]; 
$rankrwx2 = $rankrwd[5]; 
$rankrwx3 = $rankrwd[9]; 
$rankrwx4 = $rankrwd[13]; 
$rankrwx5 = $rankrwd[17]; 
$rankrwx6 = $rankrwd[21]; 

$rewardx1 = $rewardrwd[2]; 
$rewardx2 = $rewardrwd[6]; 
$rewardx3 = $rewardrwd[10]; 
$rewardx4 = $rewardrwd[14]; 
$rewardx5 = $rewardrwd[18]; 
$rewardx6 = $rewardrwd[22]; 


$sql_rwd1 = mysql_query("select * from wd_reward where username='".$user_session."' and jenis='1'");
$ada_rwd1 = mysql_num_rows($sql_rwd1);
$rowcrwd1 = mysql_fetch_array($sql_rwd1);
if($ada_rwd1 > 0){
$point1 = $rowcrwd1['pointreward'];
$status1="<img src='../images/tick.png' width='16' height='16' />";
} else {
$point1 = "";
$status1="<img src='../images/publish_x.png' width='16' height='16' />";
}

$sql_rwd2 = mysql_query("select * from wd_reward where username='".$user_session."' and jenis='2'");
$ada_rwd2 = mysql_num_rows($sql_rwd2);
$rowcrwd2 = mysql_fetch_array($sql_rwd2);
if($ada_rwd2 > 0){
$point2 = $rowcrwd2['pointreward'];
$status2="<img src='../images/tick.png' width='16' height='16' />";
} else {
$point2 = "";
$status2="<img src='../images/publish_x.png' width='16' height='16' />";
}

$sql_rwd3 = mysql_query("select * from wd_reward where username='".$user_session."' and jenis='3'");
$ada_rwd3 = mysql_num_rows($sql_rwd3);
$rowcrwd3 = mysql_fetch_array($sql_rwd3);
if($ada_rwd3 > 0){
$point3 = $rowcrwd3['pointreward'];
$status3="<img src='../images/tick.png' width='16' height='16' />";
} else {
$point3 = "";
$status3="<img src='../images/publish_x.png' width='16' height='16' />";
}

$sql_rwd4 = mysql_query("select * from wd_reward where username='".$user_session."' and jenis='4'");
$ada_rwd4 = mysql_num_rows($sql_rwd4);
$rowcrwd4 = mysql_fetch_array($sql_rwd4);
if($ada_rwd4 > 0){
$point4 = $rowcrwd4['ppointrewardoint'];
$status4="<img src='../images/tick.png' width='16' height='16' />";
} else {
$point4 = "";
$status4="<img src='../images/publish_x.png' width='16' height='16' />";
}

$sql_rwd5 = mysql_query("select * from wd_reward where username='".$user_session."' and jenis='5'");
$ada_rwd5 = mysql_num_rows($sql_rwd5);
$rowcrwd5 = mysql_fetch_array($sql_rwd5);
if($ada_rwd5 > 0){
$point5 = $rowcrwd5['pointreward'];
$status5="<img src='../images/tick.png' width='16' height='16' />";
} else {
$point5 = "";
$status5="<img src='../images/publish_x.png' width='16' height='16' />";
}
$sql_rwd6 = mysql_query("select * from wd_reward where username='".$user_session."' and jenis='6'");
$ada_rwd6 = mysql_num_rows($sql_rwd6);
$rowcrwd6 = mysql_fetch_array($sql_rwd6);
if($ada_rwd6 > 0){
$point6 = $rowcrwd6['pointreward'];
$status6="<img src='../images/tick.png' width='16' height='16' />";
} else {
$point6 = "";
$status6="<img src='../images/publish_x.png' width='16' height='16' />";
}
$sql_rwd7 = mysql_query("select * from wd_reward where username='".$user_session."' and jenis='7'");
$ada_rwd7 = mysql_num_rows($sql_rwd7);
$rowcrwd7 = mysql_fetch_array($sql_rwd7);
if($ada_rwd7 > 0){
$point7 = $rowcrwd7['pointreward'];
$status7="<img src='../images/tick.png' width='16' height='16' />";
} else {
$point7 = "";
$status7="<img src='../images/publish_x.png' width='16' height='16' />";
}

$pointnya = $point1+$point2+$point3+$point4+$point5+$point6+$point7;

$memberix = omsetkiri($user_session);
$membernanx = omsetkanan($user_session);
$memberi = $memberix - $pointnya;
$membernan = $membernanx - $pointnya;
if($memberi > 0){
	$sldmemberi = rupiah($memberi);
}else{
	$sldmemberi = "---";
}
if($membernan > 0){
	$sldmembera = rupiah($membernan);
}else{
	$sldmembera = "---";
}
if($pointnya > 0){
	$pointnyac = rupiah($pointnya);
}else{
	$pointnyac = "---";
}

if($memberi >= $batasrwx1 && $membernan >= $batasrwx1){
$qualy1="Qualified";
$reward1=$rewardx1;
$ambil1= "<a class='btn btn-sm green' href='index.php?go=withdrawlreward'><i class='fa fa-check'></i>&nbsp;Get Reward</a>";
} else {
$qualy1="Belum Qualified";
$reward1="---";
$ambil1= "---";
}
if($memberi >= $batasrwx2 && $membernan >= $batasrwx2){
$qualy2="Qualified";
$reward2=$rewardx2;
$ambil2= "<a class='btn btn-sm green' href='index.php?go=withdrawlreward'><i class='fa fa-check'></i>&nbsp;Get Reward</a>";
} else {
$qualy2="Belum Qualified";
$reward2="---";
$ambil2= "---";
}
if($memberi >= $batasrwx3 && $membernan >= $batasrwx3){
$qualy3="Qualified";
$reward3=$rewardx3;
$ambil3= "<a class='btn btn-sm green' href='index.php?go=withdrawlreward'><i class='fa fa-check'></i>&nbsp;Get Reward</a>";
} else {
$qualy3="Belum Qualified";
$reward3="---";
$ambil3= "---";
}
if($memberi >= $batasrwx4 && $membernan >= $batasrwx4){
$qualy4="Qualified";
$reward4=$rewardx4;
$ambil4= "<a class='btn btn-sm green' href='index.php?go=withdrawlreward'><i class='fa fa-check'></i>&nbsp;Get Reward</a>";
} else {
$qualy4="Belum Qualified";
$reward4="---";
$ambil4= "---";
}
if($memberi >= $batasrwx5 && $membernan >= $batasrwx5){
$qualy5="Qualified";
$reward5=$rewardx5;
$ambil5= "<a class='btn btn-sm green' href='index.php?go=withdrawlreward'><i class='fa fa-check'></i>&nbsp;Get Reward</a>";
} else {
$qualy5="Belum Qualified";
$reward5="---";
$ambil5= "---";
}
if($memberi >= $batasrwx6 && $membernan >= $batasrwx6){
$qualy6="Qualified";
$reward6=$rewardx6;
$ambil6= "<a class='btn btn-sm green' href='index.php?go=withdrawlreward'><i class='fa fa-check'></i>&nbsp;Get Reward</a>";
} else {
$qualy6="Belum Qualified";
$reward6="---";
$ambil6= "---";
}
if($memberi >= $batasrwx7 && $membernan >= $batasrwx7){
$qualy7="Qualified";
$reward7=$rewardx7;
$ambil7= "<a class='btn btn-sm green' href='index.php?go=withdrawlreward'><i class='fa fa-check'></i>&nbsp;Get Reward</a>";
} else {
$qualy7="Belum Qualified";
$reward7="---";
$ambil7= "---";
}


			
?>	               
   
           <p align="center" class="style1">Qualifikasi Reward  :</p>
  <table width="82%" border="1" align="center" cellpadding="0" cellspacing="0">
    <tr>
      <td width="40%" height="35" bgcolor="#67809F"><div align="center"><font color="#FFFFFF">Username</font></div></td>
      <td width="20%" bgcolor="#67809F"><div align="center"><font color="#FFFFFF">Omset Kiri</font> </div></td>
      <td width="20%" bgcolor="#67809F"><div align="center"><font color="#FFFFFF">Omset Kanan </font></div></td>
      <td width="20%" bgcolor="#67809F"><div align="center"><font color="#FFFFFF">Point Diambil</font> </div></td>
    </tr>
    <tr>
      <td height="33"><div align="center"><? echo $user_session; ?></div></td>
      <td><div align="center"><?= $sldmemberi; ?></div></td>
      <td><div align="center"><?= $sldmembera; ?></div></td>
      <td><div align="center"><?= $pointnyac; ?></div></td>
    </tr>
  </table>

<p>&nbsp;</p>
<script>
		function confirmActionx2(){
      var confirmed = confirm("You do not have any balance of bonus.");
      return confirmed;
}
</script>

			<div class="row">
				<div class="col-md-12">
					<!-- BEGIN EXAMPLE TABLE PORTLET-->
					<div class="portlet box blue-hoki">
						<div class="portlet-title">
							<div class="caption">
								<i class="fa fa-money"></i>&nbsp;&nbsp;Reward
							</div>
							
						</div>
						<div class="portlet-body">
							<div class="table-toolbar">
								<div class="row">
								
									<div class="col-md-6">
										
									</div>
								</div>
							</div>
							<table class="table table-striped table-hover table-bordered" id="sample_editable_1">
							<thead>
							<tr>
				 <th>Reward</th>
                                    <th>Omset Kiri</th>
                                    <th>Omset Kanan</th>
                                    <th>Pencapaian</th>
                                    <th>Reward</th>
                                    <th>Ambil Reward</th>
                                    <th>Status Withdrawl</th>
							</tr>
							</thead>
							<tbody>
	  <tr> 
                            <td><?php echo $style; ?><?php echo $rankrwx1; ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($batasrwx1); ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($batasrwx1); ?></font></td>
                            <td><?php echo $style; ?><?php echo $qualy1; ?></font></td>
                            <td><?php echo $style; ?><?php echo $reward1; ?></font></td>
                            <td><?php echo $style; ?><?php echo $ambil1; ?></font></td>
                            <td><?php echo $style; ?><?php echo $status1; ?></font></td>
                        </tr>
                                                                    
        <tr> 
                            <td><?php echo $style; ?><?php echo $rankrwx2; ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($batasrwx2); ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($batasrwx2); ?></font></td>
                            <td><?php echo $style; ?><?php echo $qualy2; ?></font></td>
                            <td><?php echo $style; ?><?php echo $reward2; ?></font></td>
                            <td><?php echo $style; ?><?php echo $ambil2; ?></font></td>
                            <td><?php echo $style; ?><?php echo $status2; ?></font></td>
                        </tr>
	 <tr> 
                            <td><?php echo $style; ?><?php echo $rankrwx3; ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($batasrwx3); ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($batasrwx3); ?></font></td>
                            <td><?php echo $style; ?><?php echo $qualy3; ?></font></td>
                            <td><?php echo $style; ?><?php echo $reward3; ?></font></td>
                            <td><?php echo $style; ?><?php echo $ambil3; ?></font></td>
                            <td><?php echo $style; ?><?php echo $status3; ?></font></td>
                        </tr>
                         <tr> 
                            <td><?php echo $style; ?><?php echo $rankrwx4; ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($batasrwx4); ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($batasrwx4); ?></font></td>
                            <td><?php echo $style; ?><?php echo $qualy4; ?></font></td>
                            <td><?php echo $style; ?><?php echo $reward4; ?></font></td>
                            <td><?php echo $style; ?><?php echo $ambil4; ?></font></td>
                            <td><?php echo $style; ?><?php echo $status4; ?></font></td>
                        </tr>
                       <tr> 
                            <td><?php echo $style; ?><?php echo $rankrwx5; ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($batasrwx5); ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($batasrwx5); ?></font></td>
                            <td><?php echo $style; ?><?php echo $qualy5; ?></font></td>
                            <td><?php echo $style; ?><?php echo $reward5; ?></font></td>
                            <td><?php echo $style; ?><?php echo $ambil5; ?></font></td>
                            <td><?php echo $style; ?><?php echo $status5; ?></font></td>
                        </tr>
							</tbody>
							</table>
						</div>
					</div>
					<!-- END EXAMPLE TABLE PORTLET-->
				</div>
			</div>
			<!-- END PAGE CONTENT -->                       
                      
               <div class="modal fade" id="ajax" role="basic" aria-hidden="true">
								<div class="modal-dialog">
									<div class="modal-content">
										<div class="modal-body">
											<img src="../assets/global/img/loading-spinner-grey.gif" alt="" class="loading">
											<span>
											&nbsp;&nbsp;Loading... </span>
										</div>
									</div>
								</div>
							</div>              
          <p>&nbsp;   </p>               
                            
                            
     <script>
		function confirmActionx2(){
      var confirmed = confirm("You do not have any balance of bonus.");
      return confirmed;
}
</script>                       
                            
        <div class="row">
				<div class="col-md-12">
					<!-- BEGIN EXAMPLE TABLE PORTLET-->
					<div class="portlet box blue-hoki">
						<div class="portlet-title">
							<div class="caption">
								<i class="fa fa-money"></i>&nbsp;&nbsp;Widhrawal Reward
							</div>
							
						</div>
						<div class="portlet-body">
							<div class="table-toolbar">
								<div class="row">
								
									<div class="col-md-6">
										
									</div>
								</div>
							</div>
							<table class="table table-striped table-hover table-bordered" id="sample_editable_1">
							<thead>
							<tr>
				 <th>Tanggal</th>
                                    <th>Point</th>
                                    <th>Reward</th>
                                    <th>Info</th>
                                    <th>Tgl Proses</th>
                                    <th>#</th>
							</tr>
							</thead>
							<tbody>
	 <?
	$db->select("id, kode, username, pointreward, reward, jenisrw, tgl, tglproses, status, ket", "wd_reward", "username='$user_session'", "tgl asc");
	$ada = $db->num_rows();
	if($ada > 0) {
		$nom=1;
		while($row=$db->fetch_row()) {
			
			
			if(is_odd($nom) == 0) {
				$class = "tblrow_ganjil";
			} else {
				$class = "tblrow_genap";
			} 	
			if($row[8] > 0) {
				$st = "<span class='badge badge-success'>Done</span>";
			} else {
				$st = "<span class='badge badge-important'>Pending</span>";
			}	
			
			if(!$row[7] || $row[7] == "0000-00-00 00:00:00"){	
		$tglpross="--";
			}else{
		$tglpross=formatgl($row[7]);
			}

?>			             
                     <tr> 
                            <td><?php echo $style; ?><?php echo formatgl($row[6]); ?></font></td>
                            <td><?php echo $style; ?><?php echo rupiah($row[3]); ?></font></td>
                            <td><?php echo $style; ?><?php echo $row[4]; ?></font></td>
                            <td><?php echo $style; ?><?php echo $row[9]; ?></font></td>
                            <td><?php echo $style; ?><?php echo $tglpross; ?></font></td>
                            <td><?php echo $style; ?><?php echo $st; ?></font></td>
                        </tr>
                                                                    
        
	<?
		}
	}
	?>
							</tbody>
							</table>
						</div>
					</div>
					<!-- END EXAMPLE TABLE PORTLET-->
				</div>
			</div>
			<!-- END PAGE CONTENT -->                                                  
                                   
                                       
                            
                    <?php } ?>






