File manager - Edit - /home/familylifersmpc/htdocs/www.familylifersmpc.com/dashboard.php
Back
<?php session_start(); error_reporting(0); include('includes/config.php'); $sid = $_SESSION['alogin']; if (strlen($_SESSION['alogin']) == "") { header("Location: login.php"); echo $_SESSION["uname"]; echo '<a href="login.php"><span>Logout</span></a></li>'; } else { ?> <style> .hda { background-color: #FF5733; color : white; font-size : 160%; position : absolute; left : 15px; top : 17px; } </style> <style> #customers { border-collapse: collapse; width : 100%; } #customers td, #customers th { border : none; padding: 8px; color : Black; white-space: nowrap; } #customers tr:nth-child(even) { background-color: #f2f2f2; } #customers tr:hover { background-color: #CFCFF9; } #customers th { padding-top : 12px; background-color: LightSeaBlue; padding-bottom : 12px; color : Black; } </style> <!DOCTYPE html> <html lang = "en"> <head> <meta charset = "utf-8"> <meta http-equiv = "X-UA-Compatible" content = "IE=edge"> <meta name = "viewport" content = "width=device-width, initial-scale=1"> <?php $sql = "SELECT * FROM tblsettings"; $query = $dbh->prepare($sql); $query->execute(); $results = $query->fetchAll(PDO::FETCH_OBJ); $cnt = 1; if ($query->rowCount() > 0) { foreach ($results as $result) { ?> <?php $BGCOLOR = $result->BGCOLOR; $COLOR1 = $result->COLOR1; $COLOR2 = $result->COLOR2; ?> <?php $cnt = $cnt + 1; } } ?> <meta name = "theme-color" content = "<?php echo htmlentities($BGCOLOR); ?>" /> <title>My Coop Account</title> <link rel = "icon" href = "favicon.ico" type = "image/icon type"> <link rel = "stylesheet" href = "css/bootstrap.min.css" media = "screen"> <link rel = "stylesheet" href = "css/font-awesome.min.css" media = "screen"> <link rel = "stylesheet" href = "css/animate-css/animate.min.css" media = "screen"> <link rel = "stylesheet" href = "css/lobipanel/lobipanel.min.css" media = "screen"> <link rel = "stylesheet" href = "css/icheck/skins/line/blue.css"> <link rel = "stylesheet" href = "css/icheck/skins/line/red.css"> <link rel = "stylesheet" href = "css/icheck/skins/line/green.css"> <link rel = "stylesheet" href = "css/main.css" media = "screen"> <script src = "js/modernizr/modernizr.min.js"></script> <style> .errorWrap { padding : 10px; margin : 0 0 20px 0; background : #fff; border-left : 4px solid #dd3d36; -webkit-box-shadow: 0 1px 1px 0 rgba(0, 0, 0, .1); box-shadow : 0 1px 1px 0 rgba(0, 0, 0, .1); } .succWrap { padding : 10px; margin : 0 0 20px 0; background : #fff; border-left : 4px solid #5cb85c; -webkit-box-shadow: 0 1px 1px 0 rgba(0, 0, 0, .1); box-shadow : 0 1px 1px 0 rgba(0, 0, 0, .1); } </style> </head> <body class = "top-navbar-fixed"> <div class = "main-wrapper"> <?php include('includes/topbar.php'); ?> <div class = "content-wrapper"> <div class = "content-container"> <?php include('includes/leftbar.php'); ?> <div class = "main-page"> <div class = "container-fluid"> <div class = "row page-title-div"> <div class = "col-sm-6"> <h2 class = "title"><img src="images/account.png" alt="My Coop Account" style="width: 7%"> <strong>MY COOP ACCOUNT</strong></h2> </div> <!-- /.col-sm-6 --> </div> <!-- /.row --> </div> <br> <div class = "container-fluid"> <?php if (isset($_SESSION['error'])) { echo " <div class = 'alert alert-danger text-center' role = 'alert'> <i class = 'fa fa-times-circle-o' style = 'font-size:50px;'></i> <br>" . $_SESSION['error'] . " <br> <button class = 'btn btn-danger' id = 'close' onclick = 'this.parentNode.parentNode.removeChild(this.parentNode); return false;' style = 'color:white;cursor:default;'><strong>Close</strong></button> </div> "; //unset error unset($_SESSION['error']); } if (isset($_SESSION['success'])) { echo " <div class='alert alert-info text-center role='alert'> <i class = 'fa fa-check-circle-o' style = 'font-size:50px;'></i> <br>" . $_SESSION['success'] . " <br> Click "<strong>Applied Loans</strong>" to check your loan status. <br> <button class = 'btn btn-primary' id = 'close' onclick = 'this.parentNode.parentNode.removeChild(this.parentNode); return false;' style = 'color:White;cursor:default;'><strong>Close </strong></button> </div> "; //unset success unset($_SESSION['success']); } ?> </div> <div class = "container-fluid"> <div class = "row"> <!-- /.col-md-6 --> <div class = "col-md-12"> <?php $sql = "SELECT DISTINCT ACCOUNT FROM tblledger WHERE USERID='" . $sid . "'"; $query = $dbh->prepare($sql); $query->execute(); $results = $query->fetchAll(PDO::FETCH_OBJ); $totalresults = 0; if ($query->rowCount() > 0) { foreach ($results as $result) { $totalresults += 1; } } ?> <h1><img src="images/savings.png" alt="Savings" style="width: 7%"> <b>My Savings <span class="badge" style="background-color:navy;color:white;font-size:16px"><?php echo htmlentities($totalresults); ?></b></h1> <div class = "panel content" style="overflow-x:auto;"> <div class = "panel-heading"> <div class = "panel-title"> <h5> </h5> </div> </div> <?php if ($msg) { ?> <div class = "alert alert-success left-icon-alert" role = "alert"> <strong>Well done!</strong><?php echo htmlentities($msg); ?> </div><?php } else if ($error) { ?> <div class = "alert alert-danger left-icon-alert" role = "alert"> <strong>Oh snap!</strong> <?php echo htmlentities($error); ?> </div> <?php } ?> <div class = "panel-body p-20"> <table id = "customers" cellspacing = "0" width = "100 %"> <thead> <tr bgcolor="#F6F6FC" class = "display table table-striped table-bordered"> <th width = "12%" align="left">SAVINGS ACCOUNT</th> <th width = "12%" class="text-right">BALANCE</th> <th width = "15%" class="text-right">AS OF</th> <th width = "10%" class="text-right">VIEW MORE DETAILS</th> </tr> </thead> <tbody> <?php $sql = "SELECT DISTINCT ACCOUNT FROM tblledger WHERE USERID='" . $sid . "'"; $query = $dbh->prepare($sql); $query->execute(); $results = $query->fetchAll(PDO::FETCH_OBJ); $cnt = 1; if ($query->rowCount() > 0) { foreach ($results as $result) { ?> <tr> <td align="left"><?php echo htmlentities($result->ACCOUNT); ?></td> <?php $sql = "SELECT * from tblledger WHERE USERID='" . $sid . "' AND ACCOUNT='" . htmlentities($result->ACCOUNT) . "' ORDER BY ID DESC LIMIT 1"; $query = $dbh->prepare($sql); $query->execute(); $results = $query->fetchAll(PDO::FETCH_OBJ); $cnt = 1; if ($query->rowCount() > 0) { foreach ($results as $result) { ?> <td align="right">₱ <?php echo htmlentities(number_format($result->BALANCE, 2)); ?></td> <td align="right"><?php echo htmlentities($result->SYSDATE); ?></td> <?php } } ?> <td align="right"><a type = "button" class = "btn btn-primary" href = "mysavings.php?item=<?php echo htmlentities($result->ACCOUNT); ?>" target = "_parent"><i class = "fa fa-eye"></i> <b>View Details</b></a></td> </tr> <?php } } ?> </tbody> </table> <!-- /.col-md-12 --> </div> </div> </div> <?php $sql = "SELECT DISTINCT CVNUM, ACCOUNT FROM tblloansledger WHERE USERID='" . $sid . "'"; $query = $dbh->prepare($sql); $query->execute(); $results = $query->fetchAll(PDO::FETCH_OBJ); $totalresults = 0; if ($query->rowCount() > 0) { foreach ($results as $result) { $totalresults += 1; } } ?> <div class = "col-md-12"> <h1><img src="images/loan.png" alt="Loans" style="width: 7%"> <b>My Loans <span class="badge" style="background-color:Navy;color:White;font-size:16px"><?php echo htmlentities($totalresults); ?></b></h1> <div class = "panel content" style="overflow-x:auto;"> <div class = "panel-heading"> <div class = "panel-title"> <h5> </h5> </div> </div> <?php if ($msg) { ?> <div class = "alert alert-success left-icon-alert" role = "alert"> <strong>Well done!</strong><?php echo htmlentities($msg); ?> </div><?php } else if ($error) { ?> <div class = "alert alert-danger left-icon-alert" role = "alert"> <strong>Oh snap!</strong> <?php echo htmlentities($error); ?> </div> <?php } ?> <div class = "panel-body p-20"> <table id = "customers" cellspacing = "0" width = "100%"> <thead> <tr bgcolor="#F6F6FC" class = "display table table-striped table-bordered"> <th width = "15%">LOANS ACCOUNT</th> <th width = "15%" class="text-right">LOAN AMOUNT</th> <th width = "20%" class="text-right">BALANCE</th> <th width = "20%" class="text-right">As Of</th> <th width = "15%" class="text-right">VIEW MORE DETAILS</th> </tr> </thead> <tbody> <?php $sql = "SELECT DISTINCT CVNUM, ACCOUNT FROM tblloansledger WHERE USERID='" . $sid . "'"; $query = $dbh->prepare($sql); $query->execute(); $results = $query->fetchAll(PDO::FETCH_OBJ); $cnt = 1; if ($query->rowCount() > 0) { foreach ($results as $result) { ?> <tr> <td><?php echo htmlentities($result->ACCOUNT); ?></td> <?php $sql = "SELECT * from tblloansledger WHERE USERID='" . $sid . "' AND CVNUM='" . htmlentities($result->CVNUM) . "' ORDER BY ID DESC LIMIT 1"; $query = $dbh->prepare($sql); $query->execute(); $results = $query->fetchAll(PDO::FETCH_OBJ); $cnt = 1; if ($query->rowCount() > 0) { foreach ($results as $result) { ?> <td class="text-right">₱ <?php echo htmlentities(number_format($result->LAMOUNT, 2)); ?></td> <td class="text-right">₱ <?php echo htmlentities(number_format($result->BALANCE, 2)); ?></td> <td class="text-right"><?php echo htmlentities($result->ENTRYDATE); ?></td> <?php } } ?> <td class="text-right"><a type = "button" class = "btn btn-primary" href = "myloans.php?item=<?php echo htmlentities($result->CVNUM); ?>&acn=<?php echo htmlentities($result->ACCOUNT); ?>" target = "_parent"><i class = "fa fa-eye"></i> <b>View Details</b></a></td> </tr> <?php } } ?> </tbody> </table> <!-- /.col-md-12 --> </div> </div> </div> <!-- /.col-md-6 --> </div> <!-- /START OF BUTTON COMMENT <div class = "row"> <div class = "col-lg-4 col-md-3 col-sm-6 col-xs-12"> <a class = "dashboard-stat" style = "background-color:#57A0D3;" href = "registerLoan_form.php"> <span class = "number color-white">Loan Application</span> <span class = "name color-white">Apply for a loan online</span> <span class = "bg-icon"><i class = "fa fa-clipboard" aria-hidden = "true"></i></span> </a> </div> <div> <div class = "col-lg-4 col-md-3 col-sm-6 col-xs-12"> <a class = "dashboard-stat" style = "background-color:#1F618D;" href = "loans_applied.php"> <span class = "number color-white">Applied loans</span> <span class = "name color-white">Check status of loans applied online</span> <span class = "bg-icon"><i class = "fa fa-newspaper-o"></i></span> </a> </div> </div> </div> END OF BUTTON COMMENT --> <!-- /.section --> </div> <!-- /.main-page --> <br><br> </div> <!-- /.content-container --> </div> <!-- /.content-wrapper --> </div> <!-- /.main-wrapper --> <!-- ========== COMMON JS FILES ========== --> <script src = "js/jquery/jquery-2.2.4.min.js"></script> <script src = "js/jquery-ui/jquery-ui.min.js"></script> <script src = "js/bootstrap/bootstrap.min.js"></script> <script src = "js/pace/pace.min.js"></script> <script src = "js/lobipanel/lobipanel.min.js"></script> <script src = "js/iscroll/iscroll.js"></script> <!-- ========== PAGE JS FILES ========== --> <script src = "js/prism/prism.js"></script> <script src = "js/waypoint/waypoints.min.js"></script> <script src = "js/counterUp/jquery.counterup.min.js"></script> <script src = "js/amcharts/amcharts.js"></script> <script src = "js/amcharts/serial.js"></script> <script src = "js/amcharts/plugins/export/export.min.js"></script> <link rel = "stylesheet" href = "js/amcharts/plugins/export/export.css" type = "text/css" media = "all" /> <script src = "js/amcharts/themes/light.js"></script> <script src = "js/toastr/toastr.min.js"></script> <script src = "js/icheck/icheck.min.js"></script> <!-- ========== THEME JS ========== --> <script src = "js/main.js"></script> <script src = "js/production-chart.js"></script> <script src = "js/traffic-chart.js"></script> <script src = "js/task-list.js"></script> </body> <div class = "foot"> <footer> </footer> </div> <style> .foot { text-align: center; } </style> </html> <?php } ?>
| ver. 1.4 |
Github
|
.
| PHP 7.4.33 | Generation time: 0.02 |
proxy
|
phpinfo
|
Settings