Your IP : 216.73.216.26


Current Path : /home2/wtmwscom/www/member/
Upload File :
Current File : /home2/wtmwscom/www/member/report_installment.php

<?php 
$title= "Installment Report";
include 'header.php';
$uid = $_SESSION['userid'];
?>
<h1>Installment Report</h1>
<?php echo getMessage();?>
    <section>
        <table style="width: 100%;">
          <thead>
            <tr>
              <th>S. No.</th>
              <th>User</th>
              <th>Month</th>
              <th>Amount</th>
              <th>From Date</th>
              <th>To Date</th>
              <th>Status</th>
            </tr>
          </thead>
          <tbody>
            <?php
            $result = mysqli_query($connection, "SELECT * FROM `installment` WHERE uid = '".$uid."' ORDER BY `recid` ASC");
            $i=1;
            while ($row = mysqli_fetch_object($result)){
            ?>
                <tr <?php if($i%2){echo "class='light'";}else{echo "class='dark'";}?>>
                  <td><?php echo $i; ?></td>
                  <td><?php echo get_user($uid).' ('.$_GET['login_id'].')';?></td>
                  <td><?php echo $row->month; ?></td>
                  <td><?php echo $row->amount; ?></td>
                  <td><?php echo date("d M, Y", strtotime($row->from_date)); ?></td>
                  <td><?php echo date("d M, Y", strtotime($row->to_date)); ?></td>
                  <td><?php if($row->status == 1){ echo 'Paid';}elseif($row->status == 0){ echo 'Due'; }?></td>
                </tr>
            <?php
            $i++;
            }
            ?>
          </tbody>
        </table>
      </section>
<?php include 'footer.php';?>