<?php include "layouts/menu.php"; ?> 
    <?php $hpl=$_REQUEST['hpl'];?>
  <!--  page-wrapper -->
         <div class="right_col" role="main">
            <div class="row">
                 <!-- page header -->
                <div class="col-lg-12">
                    <h1 class="page-header  alert alert-info">Due Details</h1>
                </div>
                <!--end page header -->
            </div>
            <div class="row">
                <div class="col-lg-12">
                    <!-- Form Elements -->
                    <div class="panel panel-default">
                        <div class="panel-heading">
                            Details
                        </div>
                        <div class="panel-body">
                            <div class="row">
   <div id="mydiv">
  <input type="button" value="Print" onclick="PrintElem('#mydiv')"  style="margin:20px;">
   <div class="alert alert-info">Monthly Due</div>
  
                    <?php
					
						$qry=mysqli_query($conn, "select * from user where mfin='$mfin' &&  hpl='$hpl'");
						$n=mysqli_num_rows($qry);
						if($n==0)
						{
							echo "Nothing To Display";
						}
						else
					{ 
						?></p>
					<div class="table-responsive">
  <table class="table table-bordered table-hover"><thead>
  <tr class="info">
						<th>Name</th>
						
						<th>Hpl</th><th>MAP</th>
						<th>Duemonth</th>
						<th>Duedate</th>
						<th>Dueamount</th>
						<th>Interest</th>
						<th>Amt W/o</th>
						<th>Pay Months</th>
						<th>Total Paid Months</th>
						<th>Paydate</th>
						<th>Fine</th>
						<th>Bal</th>
						<th>Amount</th>
						<th>Delete</th>
					</tr></thead>
					<?php 
					while($row=mysqli_fetch_array($qry))
						{
					?>
					<tbody><tr class="warning">
					<col width="100px">
						<td><?php echo $row['name'];?></td>
						
						<td><?php echo $row['hpl'];?></td><td><a href="https://www.google.com/maps/?q=<?php echo $row['lat'];?>,<?php echo $row['lang'];?>" target="_blank">map</a></td>
						<td><?php echo $row['no'];?></td>
						<td><?php echo $row['duedate'];?></td>
						<td><?php echo $row['dueamount'];?></td>
						<td><?php echo $row['rno'];?></td>
						<td><?php echo $row['pass'];?></td>
						<td><?php echo $row['paymnt'];?></td>
						<td><?php echo $row['payyr'];?></td>
						<td><?php echo $row['paydate'];?></td>
						
						
						<td><?php echo $row['fine'];?></td>
						<td><?php echo $row['bal'];?></td>
						<td><?php echo $row['urname'];?></td>
						<td><a href="ddelete.php?hpl=<?php echo $row['hpl'];?>&name=<?php echo $row['name'];?>&fid=<?php echo $row['fid'];?>">More Info</a></td>
					</tr></tbody>
					<?php
						}
					}
				
					?>
					</table>
</div></div>
</div></div>
</div></div></div> <?php include "layouts/footer.php"; ?></body></html>