Banking System
Banking System
Banking System
COMMERCE
VIDYAVIHAR, MUMBAI-77
PROJECT REPORT
ON
BY
BHAVYA R PATEL
T.Y.BSC(COMPUTER SCIENCE)
ROLL NO:66
PROJECT GUIDE
Prof.Poonam Pandey
HEAD OF DEPARTMENT
Prof.Swati Maurya
ACKNOWLEDGEMENT
I have great pleasure in presenting this project entitled
“FINANCIAL MANAGEMENT SYSTEM”
I take this opportunity to thank “DR. MANALI LONDHE” our
principal ok SK SOMAIYA DEGREE COLLEGE OF ARTS,
SCIENCE AND COMMERCE for giving the opportunity to
study in the institute and the most needed guidance
throughout the duration of the course.
I would also like to extend my gratitude to “MS. POONAM
PANDEY” for the timely and prestige guidance and also
provided the guidance and necessary support during each
phase of the project.
Thanking You,
BHAVYA PATEL
TABLE OF CONTENTS
E R DIAGRAM
DATABASE DESIGN
USE CASE DIAGRAM
SEQUENCE DIAGRAM
ACTIVITY DIAGRAM
CLASS DIAGRAM
CHAPTER 3: USAGE INFO
DESCRIPTION
SCREENSHOTS
CHAPTER 4: CODING
SYSTEM CODES
OBJECTIVE
FMS- Make your Bank Loan Management easy FMS is a Modern and
Responsive Loan management system. It is developed by PHP and
HTML 5. It is design and develop for companies, bank etc that require
streamlined loan control, savings account and SMS notification
system. The system also automates the savings, borrowing and
payment processes. This software is a web based application used
by most cooperative, mini – bank, micro-finance bank etc. to handle
loan and savings transaction.
FEATURES
1. SECURITY: There is a lot of security of data on this content management
system. One cannot open our system without knowing the password. Immediately
after opening login screen will appear on screen. Only after entering the correct
username and password user can operate our system.
3. EASY RETRIEVAL OF DATA: Data is retrieved easily and quick using sql
commands. On line commands are used to retrieve huge amount of data.
Though there are many online systems available on internet but this can compete
with them with some advancement in its functionality and can be used by any bank
organization to maintain their customer’s account and online transaction process.
Create Account
Login
Update Profile
Add Customer
Add Borrower
Add Employee
Manage Permissions
Manage transactions
MYWALLET
Message Passing
Report generation
Payment schedule
Delete account
Logout
ER diagram:
UML CLASS DIAGRAM:
ACTIVITY DIAGRAM:
CONTEXT DIAGRAM:
USE CASE DIAGRAM:
SEQUENCE DIAGRAM:
DATABASE DESIGN
RESULTS:
Borrowing Process
Wallet Module Description
Then enter the amount to add, the description and transaction / wallet type
Loan management
Attached required document for the loan
Payment process module
Here, you can view and delete payment records and also you can print and export payment
records to excel.
Create: It will enable the navigation tab for the Module Name located at the left side bar and
also it will enable all add button integrated in the system when checked but disabled it when
unchecked.
Read: It will enable the respective user of the platform to be able to view all record /
transaction / information placed on the platform when checked but disabled it when unchecked.
Update: It will enable all update button embedded on the platform when checked but disabled
it when unchecked.
Delete: It will enable all delete button embedded on the platform when checked but disabled it
when unchecked.
You can also View list of all users given permission as shown in the screenshot below:
Below is the modules enabled / disabled for the users or staff of the Bank.
Here, you can edit user permission, then you click on Update Module to save it.
Savings Account Module
Once you click Add to Borrower List, you will be taken to another page where you will be ask to
enter comment e.g. Application of loan as shown in the screenshot below then you will click on
save button for the customer details to appear in borrower list page:
To deposit fund to customers account, Under Savings Account Tab, Click on Deposit Money,
then you select / search the customer's account number to transfer to, Enter the Amount to
Deposit, then you click on Deposit button. NOTE: For any deposit you make on the system,
the customer will receive Credit Alert on his or her mobile phone as a confirmation that the
money have been posted.
Withdraw money
To view all Transaction and Print Transaction Receipt with official stamp on it,
Under Savings Account Tab, Click on All Transaction as shown in the image below:
The transaction fee receipt can be generated by clicking the Receipt button:
Coding phase
Index.php
<?php
$install = file_exists(__DIR__ . '/config/connect.php');
if ($install == false) {
header("location:application/install/index.php");
} else {
session_start();
error_reporting(E_ALL);
$day = date("d");
$month = date("m");
$year = date("Y");
$datein = cal_days_in_month(CAL_GREGORIAN, $month, $year);
if($day == $datein)
{
include("application/alert_sender/sms_charges.php");
}
else{
//empty action
}
include "config/connect.php";
?>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<?php
$call = mysqli_query($link, "SELECT * FROM systemset");
if(mysqli_num_rows($call) == 0)
{
echo "<script>alert('Data Not Found!'); </script>";
}
else
{
while($row = mysqli_fetch_assoc($call)){
?>
<title><?php echo $row ['title']?></title>
<?php }}?>
<?php
$call = mysqli_query($link, "SELECT * FROM systemset");
if(mysqli_num_rows($call) == 0)
{
echo "<script>alert('Data Not Found!'); </script>";
}
else
{
while($row = mysqli_fetch_assoc($call)){
?>
<link href="img/<?php echo $row['image']; ?>" rel="icon" type="dist/img">
<?php }}?>
<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
<!-- Bootstrap 3.3.6 -->
<link rel="stylesheet" href="bootstrap/css/bootstrap.min.css">
<!-- Font Awesome -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.5.0/css/font-
awesome.min.css">
<!-- Ionicons -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/ionicons/2.0.1/css/ionicons.min.css">
<!-- Theme style -->
<link rel="stylesheet" href="dist/css/AdminLTE.min.css">
<!-- iCheck -->
<link rel="stylesheet" href="plugins/iCheck/square/blue.css">
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
<style type="text/css">
<!--
.style1 {
color: #FF0000;
font-weight: bold;
}
-->
</style>
</head>
<body class="hold-transition login-page">
<div class="login-box">
<div class="login-logo">
<?php
$call = mysqli_query($link, "SELECT * FROM systemset");
if(mysqli_num_rows($call) == 0)
{
echo "<script>alert('Data Not Found!'); </script>";
}
else
{
while($row = mysqli_fetch_assoc($call)){
?>
<a href="index.php"> <img src="img/<?php echo $row ['image'] ;?>" class="img-circle" alt="User Image"
width="70" height="70"></a>
<a href="index.php"><h3 style="color: red;"><strong><?php echo $row ['name'];?></strong></h3></a>
<?php }}?>
</div>
<!-- /.login-logo -->
<div class="login-box-body">
<p class="login-box-msg">Please sign in here</p>
<form class="form" method="post" enctype="multipart/form-data">
<div align="right">
<a href="forgetpassword.php"><button type="button" class="btn btn-warning btn-flat"><i class="fa fa-mail-
reply-all"></i> Forget Password ?</button></a>
<button name="submit" type="submit" class="btn btn-success btn-flat"><i class="fa fa-
send"></i> Sign In</button>
</div>
<hr>
<?php
//include("emailfunc.php");
if(isset($_POST['submit']))
{
$username= mysqli_real_escape_string($link, $_POST['username']);
$pass= mysqli_real_escape_string($link, $_POST['pass']);
$encrypt = base64_encode($pass);
$query = mysqli_query($link, "SELECT * FROM user WHERE '$username' IN(email, username) AND password =
'$encrypt'") or die(mysqli_error($link));
$row = mysqli_fetch_array($query);
$numberOfRows = mysqli_num_rows($query);
if ($numberOfRows == 0)
{
echo '<hr>';
echo '<div class="alert alert-danger">Invalid Username or Password</div>';
echo '<hr>';
}
else
{
//$sql = mysqli_query($link,"UPDATE user SET Signal='On' WHERE Email = '$email'") or die(mysqli_error($link));
echo '<hr>';
echo '<div class="alert alert-success">You have Successfully Login</div>';
$_SESSION['tid'] = $row['id'];
echo "<script>window.location='loader.php?tid=".$_SESSION['tid']."';</script>";
}
}
?>
</form>
<section class="content">
<?php include("include/addcustomer_data.php"); ?>
</section>
</div>
<?php include("include/footer.php"); ?>
Addpermission.php
<?php include("include/header.php"); ?>
<div class="wrapper">
<?php include("include/top_bar.php"); ?>
<!-- Left side column. contains the logo and sidebar -->
<?php include("include/side_bar.php"); ?>
<!-- Content Wrapper. Contains page content -->
<div class="content-wrapper">
<section class="content">
<?php include("include/newborrowers_data.php"); ?>
</section>
</div>
<?php include("include/footer.php"); ?>
Newemployee.php
<section class="content">
<?php include("include/newborrowers_data.php"); ?>
</section>
</div>
<?php include("include/footer.php"); ?>
Process_emp.php
<?php include "../config/session.php"; ?>
<!DOCTYPE html>
<html>
<head>
<style>
.loader {
border: 16px solid #f3f3f3;
border-radius: 50%;
border-top: 16px solid blue;
border-right: 16px solid green;
border-bottom: 16px solid red;
border-left: 16px solid pink;
width: 120px;
height: 120px;
-webkit-animation: spin 2s linear infinite;
animation: spin 2s linear infinite;
margin:auto;
}
@-webkit-keyframes spin {
0% { -webkit-transform: rotate(0deg); }
100% { -webkit-transform: rotate(360deg); }
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
</style>
</head>
<body>
<br><br><br><br><br><br><br><br><br>
<div style="width:100%;text-align:center;vertical-align:bottom">
<div class="loader"></div>
<?php
if(isset($_POST['emp']))
{
$name = mysqli_real_escape_string($link, $_POST['name']);
$email = mysqli_real_escape_string($link, $_POST['email']);
$phone = mysqli_real_escape_string($link, $_POST['phone']);
$addr1 = mysqli_real_escape_string($link, $_POST['addr1']);
$addr2 = mysqli_real_escape_string($link, $_POST['addr2']);
$city = mysqli_real_escape_string($link, $_POST['city']);
$state = mysqli_real_escape_string($link, $_POST['state']);
$zip = mysqli_real_escape_string($link, $_POST['zip']);
$country = mysqli_real_escape_string($link, $_POST['country']);
$comment = mysqli_real_escape_string($link, $_POST['comment']);
$username = mysqli_real_escape_string($link, $_POST['username']);
$password = mysqli_real_escape_string($link, $_POST['password']);
$cpaswword = mysqli_real_escape_string($link, $_POST['cpassword']);
$role = "admin";
$target_dir = "../img/";
$target_file = $target_dir.basename($_FILES["image"]["name"]);
$imageFileType = pathinfo($target_file,PATHINFO_EXTENSION);
$check = getimagesize($_FILES["image"]["tmp_name"]);
$encrypt = base64_encode($password);
$id = "Loan"."=".rand(10000000,340000000);
if($password != $cpaswword)
{
echo "<script>alert('The 2 Password does not match!'); </script>";
}
elseif($check == false)
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Invalid file type</span>';
}
elseif(file_exists($target_file))
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Already exists.</span>';
}
elseif($_FILES["image"]["size"] > 500000)
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Image must not more than 500KB!</span>';
}
elseif($imageFileType != "jpg" && $imageFileType != "png" && $imageFileType != "jpeg" && $imageFileType !=
"gif")
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Sorry, only JPG, JPEG, PNG & GIF Files are
allowed.</span>';
}
else{
$sourcepath = $_FILES["image"]["tmp_name"];
$targetpath = "../img/" . $_FILES["image"]["name"];
move_uploaded_file($sourcepath,$targetpath);
$location = "img/".$_FILES['image']['name'];
}
@-webkit-keyframes spin {
0% { -webkit-transform: rotate(0deg); }
100% { -webkit-transform: rotate(360deg); }
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
</style>
</head>
<body>
<br><br><br><br><br><br><br><br><br>
<div style="width:100%;text-align:center;vertical-align:bottom">
<div class="loader"></div>
<?php
$id = $_GET['id'];
$name = mysqli_real_escape_string($link, $_POST['name']);
$email = mysqli_real_escape_string($link, $_POST['email']);
$phone = mysqli_real_escape_string($link, $_POST['phone']);
$addr1 = mysqli_real_escape_string($link, $_POST['addr1']);
$addr2 = mysqli_real_escape_string($link, $_POST['addr2']);
$city = mysqli_real_escape_string($link, $_POST['city']);
$state = mysqli_real_escape_string($link, $_POST['state']);
$zip = mysqli_real_escape_string($link, $_POST['zip']);
$country = mysqli_real_escape_string($link, $_POST['country']);
$comment = mysqli_real_escape_string($link, $_POST['comment']);
$username = mysqli_real_escape_string($link, $_POST['username']);
$password = mysqli_real_escape_string($link, $_POST['password']);
$encrypt = base64_encode($password);
$image = addslashes(file_get_contents($_FILES['image']['tmp_name']));
if($image == "")
{
$update = mysqli_query($link,"UPDATE user SET
name='$name',email='$email',phone='$phone',addr1='$addr1',addr2='$addr2',city='$city',state='$state',zip='$zip',
country='$country',comment='$comment',username='$username',password='$encrypt' WHERE userid ='$id'")or
die(mysqli_error());
if(!$update)
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Unable to update employee records!</span>';
}
else{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?id='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Updating Employee.....Please Wait!</span>';
}
}
else{
$target_dir = "../img/";
$target_file = $target_dir.basename($_FILES["image"]["name"]);
$imageFileType = pathinfo($target_file,PATHINFO_EXTENSION);
$check = getimagesize($_FILES["image"]["tmp_name"]);
if($check == false)
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Invalid file type</span>';
}
elseif(file_exists($target_file))
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Already exists.</span>';
}
elseif($_FILES["image"]["size"] > 500000)
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Image must not more than 500KB!</span>';
}
elseif($imageFileType != "jpg" && $imageFileType != "png" && $imageFileType != "jpeg" &&
$imageFileType != "gif")
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Sorry, only JPG, JPEG, PNG & GIF Files are
allowed.</span>';
}
else{
$sourcepath = $_FILES["image"]["tmp_name"];
$targetpath = "../img/" . $_FILES["image"]["name"];
move_uploaded_file($sourcepath,$targetpath);
$location = "img/".$_FILES['image']['name'];
$update = mysqli_query($link,"UPDATE user SET
name='$name',email='$email',phone='$phone',addr1='$addr1',addr2='$addr2',city='$city',state='$state',zip='$zip',
country='$country',comment='$comment',username='$username',password='$encrypt',image='$location' WHERE
userid ='$id'")or die(mysqli_error());
if(!$update)
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Unable to update employee
records!</span>';
}
else{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?id='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Updating Employee.....Please
Wait!</span>';
}
}
}
?>
</div>
</body>
</html>
Process_loan_info.php
<?php include "../config/session.php"; ?>
<!DOCTYPE html>
<html>
<head>
<style>
.loader {
border: 16px solid #f3f3f3;
border-radius: 50%;
border-top: 16px solid blue;
border-right: 16px solid green;
border-bottom: 16px solid red;
border-left: 16px solid pink;
width: 120px;
height: 120px;
-webkit-animation: spin 2s linear infinite;
animation: spin 2s linear infinite;
margin:auto;
@-webkit-keyframes spin {
0% { -webkit-transform: rotate(0deg); }
100% { -webkit-transform: rotate(360deg); }
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
</style>
</head>
<body>
<br><br><br><br><br><br><br><br><br>
<div style="width:100%;text-align:center;vertical-align:bottom">
<div class="loader"></div>
<?php
if(isset($_POST['save_loan']))
{
$borrower = mysqli_real_escape_string($link, $_POST['borrower']);
$baccount = mysqli_real_escape_string($link, $_POST['account']);
$desc = mysqli_real_escape_string($link, $_POST['desc']);
$amount = mysqli_real_escape_string($link, $_POST['amount']);
$date_release = mysqli_real_escape_string($link, $_POST['date_release']);
$agent = mysqli_real_escape_string($link, $_POST['agent']);
$gname = mysqli_real_escape_string($link, $_POST['g_name']);
$gphone = mysqli_real_escape_string($link, $_POST['g_phone']);
$target_dir = "../img/";
$target_file = $target_dir.basename($_FILES["image"]["name"]);
$imageFileType = pathinfo($target_file,PATHINFO_EXTENSION);
$check = getimagesize($_FILES["image"]["tmp_name"]);
$encrypt = base64_encode($password);
$id = "Loan"."=".rand(10000000,340000000);
if($password != $cpaswword)
{
echo "<script>alert('The 2 Password does not match!'); </script>";
}
elseif($check == false)
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Invalid file type</span>';
}
elseif(file_exists($target_file))
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Already exists.</span>';
}
elseif($_FILES["image"]["size"] > 500000)
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Image must not more than 500KB!</span>';
}
elseif($imageFileType != "jpg" && $imageFileType != "png" && $imageFileType != "jpeg" && $imageFileType !=
"gif")
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Sorry, only JPG, JPEG, PNG & GIF Files are
allowed.</span>';
}
else{
$sourcepath = $_FILES["image"]["tmp_name"];
$targetpath = "../img/" . $_FILES["image"]["name"];
move_uploaded_file($sourcepath,$targetpath);
$location = "img/".$_FILES['image']['name'];
<!DOCTYPE html>
<html>
<head>
<style>
.loader {
border: 16px solid #f3f3f3;
border-radius: 50%;
border-top: 16px solid blue;
border-right: 16px solid green;
border-bottom: 16px solid red;
border-left: 16px solid pink;
width: 120px;
height: 120px;
-webkit-animation: spin 2s linear infinite;
animation: spin 2s linear infinite;
margin:auto;
@-webkit-keyframes spin {
0% { -webkit-transform: rotate(0deg); }
100% { -webkit-transform: rotate(360deg); }
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
</style>
</head>
<body>
<br><br><br><br><br><br><br><br><br>
<div style="width:100%;text-align:center;vertical-align:bottom">
<div class="loader"></div>
<?php
if(isset($_POST['save_loan']))
{
$borrower = mysqli_real_escape_string($link, $_POST['borrower']);
$baccount = mysqli_real_escape_string($link, $_POST['account']);
$desc = mysqli_real_escape_string($link, $_POST['desc']);
$amount = mysqli_real_escape_string($link, $_POST['amount']);
$date_release = mysqli_real_escape_string($link, $_POST['date_release']);
$agent = mysqli_real_escape_string($link, $_POST['agent']);
$gname = mysqli_real_escape_string($link, $_POST['g_name']);
$gphone = mysqli_real_escape_string($link, $_POST['g_phone']);
$encrypt = base64_encode($password);
$id = "Loan"."=".rand(10000000,340000000);
if($password != $cpaswword)
{
echo "<script>alert('The 2 Password does not match!'); </script>";
}
elseif($check == false)
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Invalid file type</span>';
}
elseif(file_exists($target_file))
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Already exists.</span>';
}
elseif($_FILES["image"]["size"] > 500000)
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Image must not more than 500KB!</span>';
}
elseif($imageFileType != "jpg" && $imageFileType != "png" && $imageFileType != "jpeg" && $imageFileType !=
"gif")
{
echo '<meta http-equiv="refresh"
content="2;url=view_emp.php?tid='.$id.'&&mid='.base64_encode("409").'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Sorry, only JPG, JPEG, PNG & GIF Files are
allowed.</span>';
}
else{
$sourcepath = $_FILES["image"]["tmp_name"];
$targetpath = "../img/" . $_FILES["image"]["name"];
move_uploaded_file($sourcepath,$targetpath);
$location = "img/".$_FILES['image']['name'];
$insert = mysqli_query($link, "INSERT INTO loan_info
VALUES('','$borrower','$baccount','$desc','$amount','$date_release','$agent','$gname','$gphone','$g_address','$g_
rela','$location','$status','$remarks','$pay_date','$amount_topay','$teller','$remark','$upstatus')") or die
(mysqli_error($link));
if(!$insert)
{
echo '<meta http-equiv="refresh" content="2;url=newloans.php?tid='.$_SESSION['tid'].'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Unable to Save Loan Information.....Please try again
later!</span>';
}
else{
echo '<meta http-equiv="refresh" content="2;url=listloans.php?tid='.$_SESSION['tid'].'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Saving Loan Information.....4 more steps to complete the
request.</span>';
}
}
}
?>
</div>
</body>
</html>
Process_pmt.php
<?php include "../config/session.php"; ?>
<!DOCTYPE html>
<html>
<head>
<style>
.loader {
border: 16px solid #f3f3f3;
border-radius: 50%;
border-top: 16px solid blue;
border-right: 16px solid green;
border-bottom: 16px solid red;
border-left: 16px solid pink;
width: 120px;
height: 120px;
-webkit-animation: spin 2s linear infinite;
animation: spin 2s linear infinite;
margin:auto;
}
@-webkit-keyframes spin {
0% { -webkit-transform: rotate(0deg); }
100% { -webkit-transform: rotate(360deg); }
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
</style>
</head>
<body>
<br><br><br><br><br><br><br><br><br>
<div style="width:100%;text-align:center;vertical-align:bottom">
<div class="loader"></div>
<?php
$id = $_GET['id'];
$acte = mysqli_real_escape_string($link, $_POST['acte']);
$account_no = mysqli_real_escape_string($link, $_POST['account']);
$customer = mysqli_real_escape_string($link, $_POST['customer']);
$loan = mysqli_real_escape_string($link, $_POST['loan']);
$pay_date = mysqli_real_escape_string($link, $_POST['pay_date']);
$amount_to_pay = mysqli_real_escape_string($link, $_POST['amount_to_pay']);
$remarks = mysqli_real_escape_string($link, $_POST['remarks']);
$update = mysqli_query($link,"UPDATE payments SET
account='$acte',account_no='$account_no',customer='$customer',loan='$loan',pay_date='$pay_date',amount_to_
pay='$amount_to_pay',remarks='$remarks' WHERE id ='$id'")or die(mysqli_error());
if(!$update)
{
echo '<meta http-equiv="refresh" content="2;url=view_pmt.php?tid='.$id.'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Unable to update payment records!</span>';
}
else{
echo '<meta http-equiv="refresh" content="2;url=view_pmt.php?id='.$id.'">';
echo '<br>';
echo'<span class="itext" style="color: #FF0000">Updating Payment.....Please Wait!</span>';
}
?>
</div>
</body>
</html>
Savings.php
<?php include "../config/session.php"; ?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<?php
$call = mysqli_query($link, "SELECT * FROM systemset");
if(mysqli_num_rows($call) == 0)
{
echo "<script>alert('Data Not Found!'); </script>";
}
else
{
while($row = mysqli_fetch_assoc($call)){
?>
<link href="../img/<?php echo $row['image']; ?>" rel="icon" type="dist/img">
<?php }}?>
<?php
$call = mysqli_query($link, "SELECT * FROM systemset");
while($row = mysqli_fetch_assoc($call)){
?>
<title><?php echo $row ['title']?></title>
<!-- Tell the browser to be responsive to screen width -->
<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
<!-- Bootstrap 3.3.6 -->
<link rel="stylesheet" href="../bootstrap/css/bootstrap.min.css">
<!-- Font Awesome -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.5.0/css/font-
awesome.min.css">
<!-- Ionicons -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/ionicons/2.0.1/css/ionicons.min.css">
<!-- Theme style -->
<link rel="stylesheet" href="../dist/css/AdminLTE.min.css">
<!-- AdminLTE Skins. Choose a skin from the css/skins
folder instead of downloading all of them to reduce the load. -->
<link rel="stylesheet" href="../dist/css/skins/_all-skins.min.css">
<!-- iCheck -->
<link rel="stylesheet" href="../plugins/iCheck/flat/blue.css">
<!-- Morris chart -->
<link rel="stylesheet" href="../plugins/morris/morris.css">
<!-- jvectormap -->
<link rel="stylesheet" href="../plugins/jvectormap/jquery-jvectormap-1.2.2.css">
<!-- Date Picker -->
<link rel="stylesheet" href="../plugins/datepicker/datepicker3.css">
<!-- Daterange picker -->
<link rel="stylesheet" href="../plugins/daterangepicker/daterangepicker.css">
<!-- bootstrap wysihtml5 - text editor -->
<link rel="stylesheet" href="../plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.min.css">
<link rel="stylesheet" href="../dist/css/style.css" />
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script type="text/javascript" src="../dist/js/calendar.js"></script>
<strong> <link rel="stylesheet" href="../plugins/datatables/dataTables.bootstrap.css"></strong>
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
</head>
<body class="hold-transition skin-blue sidebar-mini">
<div class="wrapper">
<header class="main-header">
<!-- Logo -->
<a href="application/index.php" class="logo">
<!-- mini logo for sidebar mini 50x50 pixels -->
<span class="logo-mini"><?php echo $row ['abb'];?></span>
<!-- logo for regular state and mobile devices -->
<span class="logo-lg"><?php echo $row ['name'];?></span>
</a>
<?php }?>
<!-- Header Navbar: style can be found in header.less -->
<nav class="navbar navbar-static-top">
<!-- Sidebar toggle button-->
<a href="#" class="sidebar-toggle" data-toggle="offcanvas" role="button">
<span class="sr-only">Toggle navigation</span>
</a>
<div class="navbar-custom-menu">
<ul class="nav navbar-nav">
</li>
<!-- Notifications: style can be found in dropdown.less -->
<ul class="dropdown-menu">
<li>
<!-- inner menu: contains the actual data -->
<ul class="menu">
</ul>
</li>
</ul>
</li>
<!-- Tasks: style can be found in dropdown.less -->
<li class="dropdown tasks-menu">
<ul class="dropdown-menu">
<li>
<!-- inner menu: contains the actual data -->
<ul class="menu">
<li><!-- Task item -->
</li>
<!-- end task item -->
</li>
<!-- end task item -->
</ul>
</li>
<li class="footer">
<a href="#"></a>
</li>
</ul>
</li>
<!-- User Account: style can be found in dropdown.less -->
<li class="dropdown user user-menu">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
<?php
$id = $_SESSION['tid'];
$call = mysqli_query($link, "SELECT * FROM user WHERE id = '$id'");
if(mysqli_num_rows($call) == 0)
{
echo "<script>alert('Data Not Found!'); </script>";
}
else
{
while($row = mysqli_fetch_assoc($call))
{
?>
<img src="../<?php echo $row['image'];?>" class="user-image" alt="User Image">
<span class="hidden-xs"><?php echo $row ['name'] ;?></span>
</a>
<ul class="dropdown-menu">
<!-- User image -->
<li class="user-header">
<img src="../<?php echo $row['image'];?>" class="img-circle" alt="User Image">
<p>
<?php echo 'Username:'. $row ['username'];?>
</p>
<?php }}?>
</li>
</div>
<div class="col-xs-4 text-center">
<a href="listborrowers.php?id=<?php echo $_SESSION['tid']; ?>">Contacts</a>
</div>
<div class="col-xs-4 text-center">
<a href="inboxmessage.php?id=<?php echo $_SESSION['tid']; ?>">Mailbox</a>
</div>
</div>
<!-- /.row -->
</li>
<!-- Menu Footer-->
<li class="user-footer">
<div class="pull-left">
<a href="inboxmessage.php?id=<?php echo $_SESSION['tid']; ?>" class="btn
btn-info btn-flat">Message</a> </div>
<div class="pull-right">
<a href="../logout.php" class="btn btn-warning btn-flat"><i class="fa fa-sign-out"></i>Sign out</a>
</div>
</li>
</ul>
</li>
<!-- Control Sidebar Toggle Button -->
<li>
<a href="#" data-toggle="control-sidebar"><i class="fa fa-gears"></i></a>
</li>
</ul>
</div>
</nav>
</header>
<!-- Left side column. contains the logo and sidebar -->
<aside class="main-sidebar">
<!-- sidebar: style can be found in sidebar.less -->
<section class="sidebar">
<!-- Sidebar user panel -->
<div class="user-panel">
<div class="pull-left image">
<?php
$id = $_SESSION['tid'];
$call = mysqli_query($link, "SELECT * FROM user WHERE id = '$id'");
if(mysqli_num_rows($call) == 0)
{
echo "<script>alert('Data Not Found!'); </script>";
}
else
{
while($row = mysqli_fetch_assoc($call))
{
?>
<img src="../<?php echo $row['image'];?>" class="img-circle" alt="User Image">
</div>
<div class="pull-left info">
<p><?php echo $row ['username'] ;?></p>
<a href="#"><i class="fa fa-circle text-success"></i> Online</a>
<?php }}?>
</div>
</div>
<!-- search form -->
?>
<ul class="sidebar-menu">
<li class="header">MAIN NAVIGATION</li>
<li><a href="dashboard.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-
dashboard"></i> <span>Dashbord</span></a></li>
<li class="treeview">
<a href="#">
<i class="fa fa-users"></i> <span>Borrowers</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li><a href="newborrowers.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-
circle-o"></i> New Borrowers</a></li>
<li><a href="listborrowers.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-circle-o"></i>List
Borrowers</a></li>
</ul>
</li>
<li class="treeview">
<a href="#">
<i class="fa fa-book"></i> <span>Message</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li class="active"><a href="newmessage.php?id=<?php echo $_SESSION['tid']; ?>"><i
class="fa fa-circle-o"></i> New Message</a></li>
<li><a href="inboxmessage.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-circle-o"></i>Inbox
Message</a></li>
<li><a href="outboxmessage.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-circle-o"></i>Outbox
Message</a></li>
</ul>
</li>
<li class="treeview">
<a href="#">
<i class="fa fa-dollar"></i> <span>Payments</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li class="active"><a href="newpayments.php?id=<?php echo $_SESSION['tid']; ?>"><i
class="fa fa-circle-o"></i> New Payment</a></li>
<li><a href="listpayment.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-circle-o"></i>List
Payments</a></li>
</ul>
</li>
<li class="treeview">
<a href="#">
<i class="fa fa-user"></i> <span>Employee</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li class="active"><a href="newemployee.php?id=<?php echo $_SESSION['tid']; ?>"><i
class="fa fa-circle-o"></i> New Employee</a></li>
<li><a href="listemployee.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-circle-o"></i>List
Employee</a></li>
</ul>
</li>
</section>
<!-- /.sidebar -->
</aside>
<?php }}?>
<!-- Content Wrapper. Contains page content -->
<div class="content-wrapper">
<section class="content">
<div class="box">
<div class="box-body">
<div class="panel panel-success">
<div class="panel-heading">
<h3 class="panel-title"><i class="fa fa-money"></i>Savings Account</h3>
</div>
<div class="box-body">
<br>
<br>
<br>
<br>
<br>
<br>
</div>
</div>
</section>
</div>
<!-- /.content-wrapper -->
<footer class="main-footer">
<div class="pull-right hidden-xs">
<b>Version</b> 2.4.2
</div>
<?php $sql = "SELECT footer FROM systemset";
$result = mysqli_query($link,$sql);
if(!$result)
{
echo '
<div class="alert alert-error">
<button type="button" class="close" data-dismiss="alert">×</button>
<strong>Warning!</strong> Unable to select! check database con.
</div>';
}
else
{
while ($row=mysqli_fetch_array($result))
{
?>
<strong> <?php echo $row ['footer'];?> </strong>
<?php }}?>
</footer>
<!-- Control Sidebar -->
<aside class="control-sidebar control-sidebar-dark">
<!-- Create the tabs -->
<ul class="nav nav-tabs nav-justified control-sidebar-tabs">
<li><a href="#control-sidebar-home-tab" data-toggle="tab"><i class="fa fa-home"></i></a></li>
<li><a href="#control-sidebar-settings-tab" data-toggle="tab"><i class="fa fa-gears"></i></a></li>
</ul>
<!-- Tab panes -->
<div class="tab-content">
<!-- Home tab content -->
<div class="tab-pane" id="control-sidebar-home-tab">
<h3 class="control-sidebar-heading">Recent Activity</h3>
<ul class="control-sidebar-menu">
<li>
<a href="javascript:void(0)">
<i class="menu-icon fa fa-birthday-cake bg-red"></i>
<div class="menu-info">
<h4 class="control-sidebar-subheading">Langdon's Birthday</h4>
<p>Will be 23 on April 24th</p>
</div>
</a>
</li>
<li>
<a href="javascript:void(0)">
<i class="menu-icon fa fa-user bg-yellow"></i>
<div class="menu-info">
<h4 class="control-sidebar-subheading">Frodo Updated His Profile</h4>
<p>New phone +1(800)555-1234</p>
</div>
</a>
</li>
<li>
<a href="javascript:void(0)">
<i class="menu-icon fa fa-envelope-o bg-light-blue"></i>
<div class="menu-info">
<h4 class="control-sidebar-subheading">Nora Joined Mailing List</h4>
<p>nora@example.com</p>
</div>
</a>
</li>
<li>
<a href="javascript:void(0)">
<i class="menu-icon fa fa-file-code-o bg-green"></i>
<div class="menu-info">
<h4 class="control-sidebar-subheading">Cron Job 254 Executed</h4>
<p>Execution time 5 seconds</p>
</div>
</a>
</li>
</ul>
<!-- /.control-sidebar-menu -->
if ( $result == "" )
{
$result = "\nNo Record(s) Found!\n";
}
header("Content-type: application/octet-stream");
header("Content-Disposition: attachment; filename=export.xls");
header("Pragma: no-cache");
header("Expires: 0");
print "$header\n$result";
?>
Transfer.php
<?php include "../config/session.php"; ?>
<?php
if(isset($_POST['transfer']))
{
$tid = $_SESSION['tid'];
$amount = mysqli_real_escape_string($link, $_POST['amount']);
$desc = mysqli_real_escape_string($link, $_POST['desc']);
$wtype = "transfer";
$transfer_to = mysqli_real_escape_string($link, $_POST['transfer_to']);
$slec = mysqli_query($link, "SELECT * FROM twallet WHERE tid = '$tid'") or die (mysqli_error($link));
while($have = mysqli_fetch_array($slec))
{
$Total = $have['Total'];
$Balance = $Total - $amount;
$update1 = mysqli_query($link, "UPDATE twallet SET Total = '$Balance' WHERE tid = '$tid'") or die
(mysqli_error($link));
$insert = mysqli_query($link, "INSERT INTO mywallet VALUES('','$transfer_to','$amount','$desc','$wtype',NOW())")
or die (mysqli_error($link));
if(!($update1 && $insert))
{
echo "<script>alert('Fund Not Transfer.....Please try again later!'); </script>";
echo "<script>window.location='mywallet.php?tid=".$_SESSION['tid']."'; </script>";
}
else{
echo "<script>alert('Fund Transfered Successfully!'); </script>";
echo "<script>window.location='mywallet.php?tid=".$_SESSION['tid']."'; </script>";
}
}
}
?>
Update_loans_data.php
<div class="row">
<section class="content">
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Borrower</label>
<div class="col-sm-10">
<?php
$get = mysqli_query($link, "SELECT * FROM borrowers WHERE id =
'$borrower'") or die (mysqli_error($link));
while($rows = mysqli_fetch_array($get))
{
?>
<input name="borrower" type="text" class="form-control"
value=<?php echo $rows['fname'].' '.$rows['lname']; ?> readonly>
<?php } ?>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Account</label>
<div class="col-sm-10">
<input name="account" type="text" class="form-control" value="<?php echo $row['baccount']; ?>"
readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Amount</label>
<div class="col-sm-10">
<input name="amount" type="text" class="form-control" value="<?php echo $row['amount']; ?>"
readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Description</label>
<div class="col-sm-10">
<textarea name="desc" class="form-control" rows="4" cols="80"
readonly><?php echo $row['desc']; ?></textarea>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Date Release</label>
<div class="col-sm-10">
<div class="input-group date">
<div class="input-group-addon">
<i class="fa fa-calendar"></i>
</div>
<input name="date_release" type="text" class="form-control pull-right" value="<?php echo
$row['date_release']; ?>" readonly>
</div>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Agent</label>
<div class="col-sm-10">
<input name="agent" type="text" class="form-control" value="<?php echo $row['agent']; ?>" readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Status</label>
<div class="col-sm-10">
<input name="status" type="text" class="form-control" value="<?php echo $row['status'];
?>"readonly="readonly">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Remarks</label>
<div class="col-sm-10">
<textarea name="remarks" class="form-control" rows="4"
cols="80" readonly="readonly"><?php echo $row['remarks']; ?></textarea>
</div>
</div>
<hr>
<div class="alert-danger"> GUARANTOR INFORMATION</div>
<hr>
<div class="form-group">
<label for="" class="col-sm-2 control-label"
style="color:#009900">Gurantor's Passport</label>
<div class="col-sm-10">
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Relationship</label>
<div class="col-sm-10">
<input name="grela" type="text" class="form-control" value="<?php echo $row['rela']; ?>"
readonly="readonly">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Guarantor's Name</label>
<div class="col-sm-10">
<input name="agent" type="text" class="form-control" value="<?php echo $row['g_name']; ?>"
readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Guarantor's Phone Number</label>
<div class="col-sm-10">
<input name="agent" type="text" class="form-control" value="<?php echo $row['g_phone']; ?>"
readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Guarantor's Address</label>
<div class="col-sm-10">
<textarea name="gaddress" class="form-control" rows="4"
cols="80" readonly="readonly"><?php echo $row['g_address']; ?></textarea>
</div>
</div>
<hr>
<div class="alert-danger"> PAYMENT INFORMATION</div>
<hr>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Current Balance</label>
<div class="col-sm-10">
<input name="user" type="text" class="form-control" value="0.00" readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Payment Date</label>
<div class="col-sm-10">
<div class="input-group date">
<div class="input-group-addon">
<i class="fa fa-calendar"></i>
</div>
<input name="pay_date" type="text" class="form-control pull-right" value="<?php echo
$row['pay_date']; ?>" readonly>
</div>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Amount to Pay</label>
<div class="col-sm-10">
<input name="amount_topay" type="number" class="form-control" value="<?php echo
$row['amount_topay']; ?>" readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Teller By</label>
<div class="col-sm-10">
<input name="teller" type="text" class="form-control" value="<?php echo $row['teller']; ?>" readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Remarks</label>
<div class="col-sm-10">
<textarea name="remark" class="form-control" rows="4"
cols="80" readonly="readonly"><?php echo $row['remarks']; ?></textarea>
</div>
</div>
</div>
</form>
<?php } ?>
</div>
<!-- /.tab-pane -->
<div class="tab-pane active" id="tab_2">
<form method="post">
<table>
<div align="center"><h4>Additional Fees</h4></div>
<tbody>
<?php
$id = $_GET['id'];
$search = mysqli_query($link, "SELECT * FROM additional_fees WHERE get_id = '$id'") or die (mysqli_error($link));
while($have = mysqli_fetch_array($search))
{
$idme= $have['id'];
?>
<tr>
<td width="30"><input id="optionsCheckbox" class="uniform_on"
name="selector[]" type="checkbox" value="<?php echo $idme; ?>" checked></td>
<td width="800"><input name="fee[]" type="text" class="form-control"
placeholder="Fee" value="<?php echo $have['fee']; ?>"></td>
<td width="300"><input name="amount[]" type="number" class="form-
control" placeholder="Amount" value="<?php echo $have['Amount']; ?>"></td>
</tr>
<?php } ?>
</tbody>
</table>
<div align="left">
<div class="box-footer">
<button type="submit" class="btn btn-success btn-flat"
name="add_fees_rows"><i class="fa fa-plus"> Add Row</i></button>
<button name="delrow" type="submit" class="btn btn-danger btn-flat"><i
class="fa fa-trash"> Delete Row</i></button>
</div>
</div>
<?php
if(isset($_POST['delrow'])){
$idm = $_GET['id'];
$id=$_POST['selector'];
$N = count($id);
if($N == 0){
echo "<script>alert('Row Not Selected!!!'); </script>";
echo
"<script>window.location='updateloans.php?id=".$idm."&&mid=".base64_encode("405")."'; </script>";
}
else{
for($i=0; $i < $N; $i++)
{
$result = mysqli_query($link,"DELETE
FROM additional_fees WHERE id ='$id[$i]'");
echo
"<script>window.location='updateloans.php?id=".$idm."&&mid=".base64_encode("405")."'; </script>";
}
}
}
?>
<?php
if(isset($_POST['add_fees_rows']))
{
$id = $_GET['id'];
$tid = $_SESSION['tid'];
$insert = mysqli_query($link, "INSERT INTO additional_fees(id,get_id,tid,fee,Amount) VALUES('','$id','$tid','','')") or
die (mysqli_error($link));
if(!$insert)
{
echo "<script>alert('Unable to add row!!!'); </script>";
echo "<script>window.location='updateloans.php?id=".$id."&&mid=".base64_encode("405")."'; </script>";
}
else{
echo "<script>window.location='updateloans.php?id=".$id."&&mid=".base64_encode("405")."'; </script>";
}
}
?>
<div align="right">
<div class="box-footer">
<button type="submit" class="btn btn-info btn-flat" name="add_fees"><i class="fa fa-
save"> Update Additional Fees</i></button>
</div>
</div>
<?php
if(isset($_POST['add_fees']))
{
$idm = $_GET['id'];
$id = $_POST['selector'];
if($id == ''){
echo "<script>alert('Row Not Selected!!!'); </script>";
echo "<script>window.location='updateloans.php?id=".$idm."&&mid=".base64_encode("405")."'; </script>";
}
else{
$i = 0;
foreach($_POST['selector'] as $s)
{
$fee = mysqli_real_escape_string($link, $_POST['fee'][$i]);
$amount = mysqli_real_escape_string($link, $_POST['amount'][$i]);
$update = mysqli_query($link, "UPDATE additional_fees SET fee = '$fee', Amount = '$amount' WHERE id = '$s'") or
die (mysqli_error($link));
$i++;
if(!$update)
{
echo "<script>alert('Record not inserted.....Please try again later!'); </script>";
}
else{
echo "<script>alert('Additional Fees/Payment Info Added Successfully!!'); </script>";
echo "<script>window.location='updateloans.php?id=".$idm."&&mid=".base64_encode("405")."'; </script>";
}
}
}
}
?>
</form>
</div>
<!-- /.tab-pane -->
<div class="tab-pane" id="tab_3">
<form class="form-horizontal" method="post" enctype="multipart/form-data">
Attachments
Accepted file types <span style="color:#FF0000">jpg, gif, png, xls, xlsx, csv, doc, docx, pdf</span>
<input name="uploaded_file" type="file" class="btn btn-info">
<div align="left">
<div class="box-footer">
<button type="submit" class="btn btn-success btn-flat" name="upload"><i
class="fa fa-upload"> Upload</i></button>
</div>
</div>
<?php
if(isset($_POST['upload']))
{
$id = $_GET['id'];
$tid = $_SESSION['tid'];
//upload random name/number
$rd2 = mt_rand(1000,9999)."_File";
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Type of Collateral:</label>
<div class="col-sm-10">
<input name="tcol" type="text" class="form-control" value="<?php echo $row['type_of_collateral']; ?>">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Model:</label>
<div class="col-sm-10">
<input name="model" type="text" class="form-control" value="<?php echo $row['model']; ?>">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Make:</label>
<div class="col-sm-10">
<input name="make" type="text" class="form-control" value="<?php echo $row['make']; ?>">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Serial Number:</label>
<div class="col-sm-10">
<input name="snumber" type="text" class="form-control" value="<?php echo $row['serial_number'];
?>">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Estimated Price:</label>
<div class="col-sm-10">
<input name="eprice" type="text" class="form-control" value="<?php echo $row['estimated_price'];
?>">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Proof of Ownership:</label>
<div class="col-sm-10">
Accepted file types <span style="color:#FF0000">jpg, gif, png, xls, xlsx, csv, doc, docx, pdf</span>
<input name="uploaded_file" type="file" class="btn btn-info">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Image:</label>
<div class="col-sm-10">
Accepted file types <span style="color:#FF0000">jpg, png </span>
<input name="image" type="file" class="btn btn-info">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Observations:</label>
<div class="col-sm-10">
<textarea name="observe" class="form-control" rows="4"
cols="80"><?php echo $row['observation']; ?></textarea>
</div>
</div>
</form>
<?php
}
else{
?>
<form class="form-horizontal" method="post" enctype="multipart/form-data">
<div align="center"><h4>Collateral</h4></div>
<div align="center">Fields in red are required</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Name:</label>
<div class="col-sm-10">
<input name="name" type="text" class="form-control">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Type of Collateral:</label>
<div class="col-sm-10">
<input name="type_of_collateral" type="text" class="form-control">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Model:</label>
<div class="col-sm-10">
<input name="model" type="text" class="form-control">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Make:</label>
<div class="col-sm-10">
<input name="make" type="text" class="form-control">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Serial Number:</label>
<div class="col-sm-10">
<input name="serial_number" type="text" class="form-control">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Estimated Price:</label>
<div class="col-sm-10">
<input name="estimated_price" type="text" class="form-control">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Proof of Ownership:</label>
<div class="col-sm-10">
Accepted file types <span style="color:#FF0000">jpg, gif, png, xls, xlsx, csv, doc, docx, pdf</span>
<input name="uploaded_file" type="file" class="btn btn-info">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Image:</label>
<div class="col-sm-10">
Accepted file types <span style="color:#FF0000">jpg, png </span>
<input name="image" type="file" class="btn btn-info">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Observations:</label>
<div class="col-sm-10">
<textarea name="observation" class="form-control" rows="4"
cols="80"></textarea>
</div>
</div>
<div align="left">
<div class="box-footer">
<button type="submit" class="btn btn-success btn-flat" name="submit"><i
class="fa fa-save"> Submit</i></button>
</div>
</div>
<?php
if(isset($_POST['submit']))
{
$id = $_GET['id'];
$tid = $_SESSION['tid'];
$name = mysqli_real_escape_string($link, $_POST['name']);
$type_of_collateral = mysqli_real_escape_string($link, $_POST['type_of_collateral']);
$model = mysqli_real_escape_string($link, $_POST['model']);
$make = mysqli_real_escape_string($link, $_POST['make']);
$serial_number = mysqli_real_escape_string($link, $_POST['serial_number']);
$estimated_price = mysqli_real_escape_string($link, $_POST['estimated_price']);
$proof_of_ownership = mysqli_real_escape_string($link, $_POST['proof_of_ownership']);
$image = addslashes(file_get_contents($_FILES['image']['tmp_name']));
$image_name = addslashes($_FILES['image']['name']);
$image_size = getimagesize($_FILES['image']['tmp_name']);
move_uploaded_file($_FILES["image"]["tmp_name"], "cimage/".$_FILES["image"]["name"]);
$cimage = "cimage/".$_FILES['image']['name'];
$observation = mysqli_real_escape_string($link, $_POST['observation']);
//upload random name/number
$rd2 = mt_rand(1000,9999)."_File";
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Term:</label>
<div class="col-sm-10">
<input name="term[]" type="text" class="form-control">
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Schedule of Payment:</label>
<div class="col-sm-10">
<select name="schedule[]" class="form-control">
<option value="Daily">Daily</option>
<option value="Weekly">Weekly</option>
<option value="Bi-weekly">Bi-weekly</option>
<option value="Monthly">Monthly</option>
<option value="Bi-Monthly">Bi-Monthly</option>
<option value="Yearly">Yearly</option>
</select>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Interest Rate:</label>
<div class="col-sm-10">
<input name="rate[]" type="text" class="form-control">%
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Penalty:</label>
<div class="col-sm-10">
<input name="penalty[]" type="text" class="form-control">%
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Schedules:</label>
<div class="col-sm-10">
<table>
<tbody>
<?php
$id = $_GET['id'];
$searchin = mysqli_query($link, "SELECT * FROM pay_schedule WHERE get_id = '$id'") or die (mysqli_error($link));
while($haveit = mysqli_fetch_array($searchin))
{
$idmet= $haveit['id'];
?>
<tr>
<td width="30"><input id="optionsCheckbox" class="uniform_on" name="selector[]"
type="checkbox" value="<?php echo $idmet; ?>" checked></td>
<td width="400"><input name="schedulek[]" type="text" class="form-control pull-right" id="datepicker"
placeholder="Schedule" value="<?php echo $haveit['schedule']; ?>"></td>
<td width="300"><input name="balance[]" type="number" class="form-control" placeholder="Balance"
value="<?php echo $haveit['balance']; ?>"></td>
<td width="200"><input name="interest[]" type="number" class="form-control"
placeholder="Interest" value="<?php echo $haveit['interest']; ?>"></td>
<td width="100"><input name="payment[]" type="number" class="form-control"
placeholder="Payment" value="<?php echo $haveit['payment']; ?>"></td>
</tr>
<?php } ?>
</tbody>
</table>
<div align="left">
<div class="box-footer">
<button type="submit" class="btn btn-success btn-flat"
name="add_sch_rows"><i class="fa fa-plus"> Add Row</i></button>
<button name="delrow2" type="submit" class="btn btn-danger btn-flat"><i
class="fa fa-trash"> Delete Row</i></button>
</div>
</div>
<?php
if(isset($_POST['delrow2'])){
$idm = $_GET['id'];
$id=$_POST['selector'];
$N = count($id);
if($id == ''){
echo "<script>alert('Row Not Selected!!!'); </script>";
echo
"<script>window.location='updateloans.php?id=".$idm."&&mid=".base64_encode("405")."'; </script>";
}
else{
for($i=0; $i < $N; $i++)
{
$result = mysqli_query($link,"DELETE
FROM pay_schedule WHERE id ='$id[$i]'");
echo
"<script>window.location='updateloans.php?id=".$idm."&&mid=".base64_encode("405")."'; </script>";
}
}
}
?>
<?php
if(isset($_POST['add_sch_rows']))
{
$id = $_GET['id'];
$tid = $_SESSION['tid'];
$insert = mysqli_query($link, "INSERT INTO pay_schedule(id,get_id,tid,schedule,balance,interest,payment)
VALUES('','$id','$tid','','','','')") or die (mysqli_error($link));
if(!$insert)
{
echo "<script>alert('Unable to Add Row.....Please try again later!'); </script>";
}
else{
echo "<script>window.location='updateloans.php?id=".$id."&&mid=".base64_encode("405")."'; </script>";
}
}
?>
</div>
</div>
</div>
<div align="right">
<div class="box-footer">
<button type="submit" class="btn btn-info btn-flat" name="add_pay_schedule"><i class="fa fa-
save"> Update Collateral</i></button>
</div>
</div>
<?php
if(isset($_POST['add_pay_schedule']))
{
$idm = $_GET['id'];
$id=$_POST['selector'];
$N = count($id);
if($N == 0){
echo "<script>alert('Row Not Selected!!!'); </script>";
echo "<script>window.location='updateloans.php?id=".$idm."&&mid=".base64_encode("405")."'; </script>";
}
else{
$i = 0;
foreach($_POST['selector'] as $s)
{
$tid = $_SESSION['tid'];
$term = mysqli_real_escape_string($link, $_POST['term'][$i]);
$day = mysqli_real_escape_string($link, $_POST['d1'][$i]);
$schedule_of_paymt = mysqli_real_escape_string($link, $_POST['schedule'][$i]);
$interest = mysqli_real_escape_string($link, $_POST['interest'][$i]);
$penalty = mysqli_real_escape_string($link, $_POST['penalty'][$i]);
$schedule = mysqli_real_escape_string($link, $_POST['schedulek'][$i]);
$balance = mysqli_real_escape_string($link, $_POST['balance'][$i]);
$interest = mysqli_real_escape_string($link, $_POST['interest'][$i]);
$payment = mysqli_real_escape_string($link, $_POST['payment'][$i]);
$update = mysqli_query($link, "UPDATE pay_schedule SET schedule = '$schedule', balance = '$balance', interest =
'$interest', payment = '$payment' WHERE id = '$s'") or die (mysqli_error($link));
$insert = mysqli_query($link, "INSERT INTO payment_schedule
VALUES('','$s','$tid','$term','$day','$schedule_of_paymt','$interest','$penalty')") or die (mysqli_error($link));
$insert = mysqli_query($link, "UPDATE loan_info SET upstatus = 'Completed' WHERE id = '$idm'") or die
(mysqli_error($link));
if(!($update && $insert))
{
echo "<script>alert('Record not inserted.....Please try again later!'); </script>";
}
else{
echo "<script>alert('Payment Scheduled Successfully!!'); </script>";
echo "<script>window.location='listloans.php?id=".$idm."&&mid=".base64_encode("405")."'; </script>";
}
}
}
}
?>
</form>
</div>
<!-- /.tab-pane -->
</div>
<!-- /.tab-content -->
</div>
</div> </div>
</div>
</div>
</div>
</div>
Update_borrowers_data.php
<div class="row">
<section class="content">
<div class="col-md-14">
<div class="nav-tabs-custom">
<ul class="nav nav-tabs">
<li><a href="#tab_1" data-toggle="tab">Personal Information</a></li>
<li class="active"><a href="#tab_2" data-toggle="tab">Financial Information</a></li>
<li><a href="#tab_3" data-toggle="tab">Attachment</a></li>
</ul>
<div class="tab-content">
<div class="tab-pane" id="tab_1">
<?php
$id = $_GET['id'];
$select = mysqli_query($link, "SELECT * FROM borrowers WHERE id = '$id'") or die (mysqli_error($link));
while($row = mysqli_fetch_array($select))
{
?>
<form class="form-horizontal" method="post" enctype="multipart/form-data">
<div class="box-body">
<div class="form-group">
<label for="" class="col-sm-2 control-label">Your Image</label>
<div class="col-sm-10">
<input type='file' name="image" onChange="readURL(this);" />
<img id="blah" src="../<?php echo $row['image']; ?>" alt="Image Here"
height="100" width="100"/>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">First Name</label>
<div class="col-sm-10">
<input name="fname" type="text" class="form-control" value="<?php echo $row['fname']; ?>"
readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Last Name</label>
<div class="col-sm-10">
<input name="lname" type="text" class="form-control" value="<?php echo $row['lname']; ?>"
readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Email</label>
<div class="col-sm-10">
<input type="email" name="email" type="text" class="form-control" value="<?php echo $row['email'];
?>" readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Mobile Number</label>
<div class="col-sm-10">
<input name="mnumber" type="text" class="form-control" value="<?php echo $row['phone']; ?>"
readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Address 1</label>
<div class="col-sm-10">
<textarea name="ad1" class="form-control" rows="4" cols="80"
readonly><?php echo $row['addrs1']; ?></textarea>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Address 2</label>
<div class="col-sm-10">
<textarea name="ad2" class="form-control" rows="4" cols="80"
readonly><?php echo $row['fname']; ?></textarea>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">City</label>
<div class="col-sm-10">
<input name="city" type="text" class="form-control" value="<?php echo $row['city']; ?>" readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">State</label>
<div class="col-sm-10">
<input name="state" type="text" class="form-control" value="<?php echo $row['state']; ?>" readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Zip Code</label>
<div class="col-sm-10">
<input name="zip" type="text" class="form-control" value="<?php echo $row['zip']; ?>" readonly>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">State</label>
<div class="col-sm-10">
<select name="country" class="form-control" required>
class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Comment</label>
<div class="col-sm-10">
<textarea name="comment" class="form-control" rows="4"
cols="80" readonly><?php echo $row['comment']; ?></textarea>
</div>
</div>
<div class="form-group">
<label for="" class="col-sm-2 control-label" style="color:#009900">Account Number</label>
<div class="col-sm-10">
<input name="account_no" type="text" class="form-control" value="<?php echo $row['account']; ?>"
readonly>
</div>
</div>
</div>
<div align="right">
<div class="box-footer">
<button type="reset" class="btn btn-primary btn-flat"><i class="fa fa-
times"> Reset</i></button>
<button name="save" type="submit" class="btn btn-success btn-flat"><i
class="fa fa-save"> Save</i></button>
</div>
</div>
</form>
<?php } ?>
</div>
<!-- /.tab-pane -->
<div class="tab-pane active" id="tab_2">
<form method="post">
<table>
<th></th>
<th align="center" width="400">Occupation</th>
<th align="center" width="300">Monthly Income</th>
<tbody>
<?php
$id = $_GET['id'];
$search = mysqli_query($link, "SELECT * FROM fin_info WHERE get_id = '$id'") or die (mysqli_error($link));
while($have = mysqli_fetch_array($search))
{
$idme= $have['id'];
?>
<tr>
<td width="30"><input id="optionsCheckbox" class="uniform_on"
name="selector[]" type="checkbox" value="<?php echo $idme; ?>" checked></td>
<td width="800"><input name="occupation[]" type="text" class="form-control"
placeholder="Occupation" value="<?php echo $have['occupation']; ?>"></td>
<td width="300"><input name="mincome[]" type="number" class="form-control" placeholder="Amount"
value="<?php echo $have['mincome']; ?>"></td>
</tr>
<?php } ?>
</tbody>
</table>
<div align="left">
<div class="box-footer">
<button type="submit" class="btn btn-success btn-flat"
name="add_fees_rows"><i class="fa fa-plus"> Add Row</i></button>
<button name="delrow" type="submit" class="btn btn-danger btn-flat"><i
class="fa fa-trash"> Delete Row</i></button>
</div>
</div>
<?php
if(isset($_POST['delrow'])){
$idm = $_GET['id'];
$id=$_POST['selector'];
$N = count($id);
if($N == 0){
echo "<script>alert('Row Not Selected!!!'); </script>";
echo
"<script>window.location='updateborrowers.php?id=".$idm."&&mid=".base64_encode("403")."'; </script>";
}
else{
for($i=0; $i < $N; $i++)
{
$result = mysqli_query($link,"DELETE
FROM fin_info WHERE id ='$id[$i]'");
echo
"<script>window.location='updateborrowers.php?id=".$idm."&&mid=".base64_encode("403")."'; </script>";
}
}
}
?>
<?php
if(isset($_POST['add_fees_rows']))
{
$id = $_GET['id'];
$tid = $_SESSION['tid'];
$insert = mysqli_query($link, "INSERT INTO fin_info(id,get_id,tid,occupation,mincome) VALUES('','$id','$tid','','')")
or die (mysqli_error($link));
if(!$insert)
{
echo "<script>alert('Unable to add row!!!'); </script>";
echo "<script>window.location='updateborrowers.php?id=".$id."&&mid=".base64_encode("403")."'; </script>";
}
else{
echo "<script>window.location='updateborrowers.php?id=".$id."&&mid=".base64_encode("403")."'; </script>";
}
}
?>
<div align="right">
<div class="box-footer">
<button type="submit" class="btn btn-info btn-flat" name="add_fees"><i class="fa fa-
save"> Update Additional Fees</i></button>
</div>
</div>
<?php
if(isset($_POST['add_fees']))
{
$idm = $_GET['id'];
$id = $_POST['selector'];
if($id == ''){
echo "<script>alert('Row Not Selected!!!'); </script>";
echo "<script>window.location='updateborrowers.php?id=".$idm."&&mid=".base64_encode("403")."'; </script>";
}
else{
$i = 0;
foreach($_POST['selector'] as $s)
{
$fee = mysqli_real_escape_string($link, $_POST['occupation'][$i]);
$amount = mysqli_real_escape_string($link, $_POST['mincome'][$i]);
$update = mysqli_query($link, "UPDATE fin_info SET occupation = '$fee', mincome = '$amount' WHERE id = '$s'") or
die (mysqli_error($link));
$i++;
if(!$update)
{
echo "<script>alert('Record not inserted.....Please try again later!'); </script>";
}
else{
echo "<script>alert('Additional Fees/Payment Info Added Successfully!!'); </script>";
echo "<script>window.location='updateborrowers.php?id=".$idm."&&mid=".base64_encode("403")."'; </script>";
}
}
}
}
?>
</form>
</div>
<!-- /.tab-pane -->
<div class="tab-pane" id="tab_3">
<form class="form-horizontal" method="post" enctype="multipart/form-data">
Attachments
Accepted file types <span style="color:#FF0000">jpg, gif, png, xls, xlsx, csv, doc, docx, pdf</span>
<input name="uploaded_file" type="file" class="btn btn-info">
<div align="left">
<div class="box-footer">
<button type="submit" class="btn btn-success btn-flat" name="upload"><i
class="fa fa-upload"> Upload</i></button>
</div>
</div>
<?php
if(isset($_POST['upload']))
{
$id = $_GET['id'];
$tid = $_SESSION['tid'];
//upload random name/number
$rd2 = mt_rand(1000,9999)."_File";
</div>
</div>
</div>
</div>
</div>
</div>
Savings.php
<?php include "../config/session.php"; ?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<?php
$call = mysqli_query($link, "SELECT * FROM systemset");
if(mysqli_num_rows($call) == 0)
{
echo "<script>alert('Data Not Found!'); </script>";
}
else
{
while($row = mysqli_fetch_assoc($call)){
?>
<link href="../img/<?php echo $row['image']; ?>" rel="icon" type="dist/img">
<?php }}?>
<?php
$call = mysqli_query($link, "SELECT * FROM systemset");
while($row = mysqli_fetch_assoc($call)){
?>
<title><?php echo $row ['title']?></title>
<!-- Tell the browser to be responsive to screen width -->
<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
<!-- Bootstrap 3.3.6 -->
<link rel="stylesheet" href="../bootstrap/css/bootstrap.min.css">
<!-- Font Awesome -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.5.0/css/font-
awesome.min.css">
<!-- Ionicons -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/ionicons/2.0.1/css/ionicons.min.css">
<!-- Theme style -->
<link rel="stylesheet" href="../dist/css/AdminLTE.min.css">
<!-- AdminLTE Skins. Choose a skin from the css/skins
folder instead of downloading all of them to reduce the load. -->
<link rel="stylesheet" href="../dist/css/skins/_all-skins.min.css">
<!-- iCheck -->
<link rel="stylesheet" href="../plugins/iCheck/flat/blue.css">
<!-- Morris chart -->
<link rel="stylesheet" href="../plugins/morris/morris.css">
<!-- jvectormap -->
<link rel="stylesheet" href="../plugins/jvectormap/jquery-jvectormap-1.2.2.css">
<!-- Date Picker -->
<link rel="stylesheet" href="../plugins/datepicker/datepicker3.css">
<!-- Daterange picker -->
<link rel="stylesheet" href="../plugins/daterangepicker/daterangepicker.css">
<!-- bootstrap wysihtml5 - text editor -->
<link rel="stylesheet" href="../plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.min.css">
<link rel="stylesheet" href="../dist/css/style.css" />
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script type="text/javascript" src="../dist/js/calendar.js"></script>
<strong> <link rel="stylesheet" href="../plugins/datatables/dataTables.bootstrap.css"></strong>
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
</head>
<body class="hold-transition skin-blue sidebar-mini">
<div class="wrapper">
<header class="main-header">
<!-- Logo -->
<a href="application/index.php" class="logo">
<!-- mini logo for sidebar mini 50x50 pixels -->
<span class="logo-mini"><?php echo $row ['abb'];?></span>
<!-- logo for regular state and mobile devices -->
<span class="logo-lg"><?php echo $row ['name'];?></span>
</a>
<?php }?>
<!-- Header Navbar: style can be found in header.less -->
<nav class="navbar navbar-static-top">
<!-- Sidebar toggle button-->
<a href="#" class="sidebar-toggle" data-toggle="offcanvas" role="button">
<span class="sr-only">Toggle navigation</span>
</a>
<div class="navbar-custom-menu">
<ul class="nav navbar-nav">
</li>
<!-- Notifications: style can be found in dropdown.less -->
<ul class="dropdown-menu">
<li>
<!-- inner menu: contains the actual data -->
<ul class="menu">
</ul>
</li>
</ul>
</li>
<!-- Tasks: style can be found in dropdown.less -->
<li class="dropdown tasks-menu">
<ul class="dropdown-menu">
<li>
<!-- inner menu: contains the actual data -->
<ul class="menu">
<li><!-- Task item -->
</li>
<!-- end task item -->
<!-- end task item -->
</li>
<!-- end task item -->
</ul>
</li>
<li class="footer">
<a href="#"></a>
</li>
</ul>
</li>
<!-- User Account: style can be found in dropdown.less -->
<li class="dropdown user user-menu">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">
<?php
$id = $_SESSION['tid'];
$call = mysqli_query($link, "SELECT * FROM user WHERE id = '$id'");
if(mysqli_num_rows($call) == 0)
{
echo "<script>alert('Data Not Found!'); </script>";
}
else
{
while($row = mysqli_fetch_assoc($call))
{
?>
<img src="../<?php echo $row['image'];?>" class="user-image" alt="User Image">
<span class="hidden-xs"><?php echo $row ['name'] ;?></span>
</a>
<ul class="dropdown-menu">
<!-- User image -->
<li class="user-header">
<img src="../<?php echo $row['image'];?>" class="img-circle" alt="User Image">
<p>
<?php echo 'Username:'. $row ['username'];?>
</p>
<?php }}?>
</li>
</div>
<div class="col-xs-4 text-center">
<a href="listborrowers.php?id=<?php echo $_SESSION['tid']; ?>">Contacts</a>
</div>
<div class="col-xs-4 text-center">
<a href="inboxmessage.php?id=<?php echo $_SESSION['tid']; ?>">Mailbox</a>
</div>
</div>
<!-- /.row -->
</li>
<!-- Menu Footer-->
<li class="user-footer">
<div class="pull-left">
<a href="inboxmessage.php?id=<?php echo $_SESSION['tid']; ?>" class="btn
btn-info btn-flat">Message</a> </div>
<div class="pull-right">
<a href="../logout.php" class="btn btn-warning btn-flat"><i class="fa fa-sign-out"></i>Sign out</a>
</div>
</li>
</ul>
</li>
<!-- Control Sidebar Toggle Button -->
<li>
<a href="#" data-toggle="control-sidebar"><i class="fa fa-gears"></i></a>
</li>
</ul>
</div>
</nav>
</header>
<!-- Left side column. contains the logo and sidebar -->
<aside class="main-sidebar">
<!-- sidebar: style can be found in sidebar.less -->
<section class="sidebar">
<!-- Sidebar user panel -->
<div class="user-panel">
<div class="pull-left image">
<?php
$id = $_SESSION['tid'];
$call = mysqli_query($link, "SELECT * FROM user WHERE id = '$id'");
if(mysqli_num_rows($call) == 0)
{
echo "<script>alert('Data Not Found!'); </script>";
}
else
{
while($row = mysqli_fetch_assoc($call))
{
?>
<img src="../<?php echo $row['image'];?>" class="img-circle" alt="User Image">
</div>
<div class="pull-left info">
<p><?php echo $row ['username'] ;?></p>
<a href="#"><i class="fa fa-circle text-success"></i> Online</a>
<?php }}?>
</div>
</div>
<!-- search form -->
?>
<ul class="sidebar-menu">
<li class="header">MAIN NAVIGATION</li>
<li><a href="dashboard.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-
dashboard"></i> <span>Dashbord</span></a></li>
<li class="treeview">
<a href="#">
<i class="fa fa-users"></i> <span>Borrowers</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li><a href="newborrowers.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-
circle-o"></i> New Borrowers</a></li>
<li><a href="listborrowers.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-circle-o"></i>List
Borrowers</a></li>
</ul>
</li>
<li class="treeview">
<a href="#">
<i class="fa fa-book"></i> <span>Message</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li class="active"><a href="newmessage.php?id=<?php echo $_SESSION['tid']; ?>"><i
class="fa fa-circle-o"></i> New Message</a></li>
<li><a href="inboxmessage.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-circle-o"></i>Inbox
Message</a></li>
<li><a href="outboxmessage.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-circle-o"></i>Outbox
Message</a></li>
</ul>
</li>
<li class="treeview">
<a href="#">
<i class="fa fa-dollar"></i> <span>Payments</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li class="active"><a href="newpayments.php?id=<?php echo $_SESSION['tid']; ?>"><i
class="fa fa-circle-o"></i> New Payment</a></li>
<li><a href="listpayment.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-circle-o"></i>List
Payments</a></li>
</ul>
</li>
<li class="treeview">
<a href="#">
<i class="fa fa-user"></i> <span>Employee</span>
<span class="pull-right-container">
<i class="fa fa-angle-left pull-right"></i>
</span>
</a>
<ul class="treeview-menu">
<li class="active"><a href="newemployee.php?id=<?php echo $_SESSION['tid']; ?>"><i
class="fa fa-circle-o"></i> New Employee</a></li>
<li><a href="listemployee.php?id=<?php echo $_SESSION['tid']; ?>"><i class="fa fa-circle-o"></i>List
Employee</a></li>
</ul>
</li>
</section>
<!-- /.sidebar -->
</aside>
<?php }}?>
<!-- Content Wrapper. Contains page content -->
<div class="content-wrapper">
<section class="content">
<div class="box">
<div class="box-body">
<div class="panel panel-success">
<div class="panel-heading">
<h3 class="panel-title"><i class="fa fa-money"></i>Savings Account</h3>
</div>
<div class="box-body">
<br>
<br>
<br>
<br>
<br>
<br>
</div>
</div>
</section>
</div>
<!-- /.content-wrapper -->
<footer class="main-footer">
<div class="pull-right hidden-xs">
<b>Version</b> 2.4.2
</div>
<?php $sql = "SELECT footer FROM systemset";
$result = mysqli_query($link,$sql);
if(!$result)
{
echo '
<div class="alert alert-error">
<button type="button" class="close" data-dismiss="alert">×</button>
<strong>Warning!</strong> Unable to select! check database con.
</div>';
}
else
{
while ($row=mysqli_fetch_array($result))
{
?>
<strong> <?php echo $row ['footer'];?> </strong>
<?php }}?>
</footer>
<!-- Control Sidebar -->
<aside class="control-sidebar control-sidebar-dark">
<!-- Create the tabs -->
<ul class="nav nav-tabs nav-justified control-sidebar-tabs">
<li><a href="#control-sidebar-home-tab" data-toggle="tab"><i class="fa fa-home"></i></a></li>
<li><a href="#control-sidebar-settings-tab" data-toggle="tab"><i class="fa fa-gears"></i></a></li>
</ul>
<!-- Tab panes -->
<div class="tab-content">
<!-- Home tab content -->
<div class="tab-pane" id="control-sidebar-home-tab">
<h3 class="control-sidebar-heading">Recent Activity</h3>
<ul class="control-sidebar-menu">
<li>
<a href="javascript:void(0)">
<i class="menu-icon fa fa-birthday-cake bg-red"></i>
<div class="menu-info">
<h4 class="control-sidebar-subheading">Langdon's Birthday</h4>
<p>Will be 23 on April 24th</p>
</div>
</a>
</li>
<li>
<a href="javascript:void(0)">
<i class="menu-icon fa fa-user bg-yellow"></i>
<div class="menu-info">
<h4 class="control-sidebar-subheading">Frodo Updated His Profile</h4>
<p>New phone +1(800)555-1234</p>
</div>
</a>
</li>
<li>
<a href="javascript:void(0)">
<i class="menu-icon fa fa-envelope-o bg-light-blue"></i>
<div class="menu-info">
<h4 class="control-sidebar-subheading">Nora Joined Mailing List</h4>
<p>nora@example.com</p>
</div>
</a>
</li>
<li>
<a href="javascript:void(0)">
<i class="menu-icon fa fa-file-code-o bg-green"></i>
<div class="menu-info">
<h4 class="control-sidebar-subheading">Cron Job 254 Executed</h4>
<p>Execution time 5 seconds</p>
</div>
</a>
</li>
</ul>
<!-- /.control-sidebar-menu -->
<section class="content">
<div class="box box-success">
<div class="box-body">
<div class="table-responsive">
<div class="box-body">
<form method="post">
<a href="dashboard.php?id=<?php echo $_SESSION['tid']; ?>&&mid=<?php echo
base64_encode("401"); ?>"><button type="button" class="btn btn-flat btn-warning"><i class="fa fa-mail-reply-
all"></i> Back</button> </a>
<button type="submit" class="btn btn-flat btn-danger" name="delete"><i class="fa fa-
times"></i> Delete</button>
<a href="add_permission.php?id=<?php echo $_SESSION['tid']; ?>&&mid=<?php echo
base64_encode("413"); ?>"><button type="button" class="btn btn-flat btn-info"><i class="fa fa-
cogs"></i> Add Permission</button></a>
<hr>
<?php
if(isset($_POST['delete'])){
$idm = $_GET['id'];
$id=$_POST['selector'];
$N = count($id);
if($id == ''){
echo "<script>alert('Row Not Selected!!!'); </script>";
echo
"<script>window.location='permission_list.php?id=".$_SESSION['tid']."&&mid=".base64_encode("413")."';
</script>";
}
else{
for($i=0; $i < $N; $i++)
{
$result = mysqli_query($link,"DELETE
FROM emp_permission WHERE tid ='$id[$i]'");
echo "<script>alert('Row Delete
Successfully!!!'); </script>";
echo
"<script>window.location='permission_list.php?id=".$_SESSION['tid']."&&mid=".base64_encode("413")."';
</script>";
}
}
}
?>
</form>
</div>
</div>
</div>
</div>
</div>
Transation.php
<div class="row">
<section class="content">
<div class="box box-success">
<div class="box-body">
<div class="table-responsive">
<div class="box-body">
<form method="post">
<a href="dashboard.php?id=<?php echo $_SESSION['tid']; ?>&&mid=<?php echo
base64_encode("401"); ?>"><button type="button" class="btn btn-flat btn-warning"><i class="fa fa-mail-reply-
all"></i> Back</button> </a>
<button type="submit" class="btn btn-flat btn-danger" name="delete"><i class="fa fa-
times"></i> Multiple Delete</button>
<a href="deposit.php?id=<?php echo $_SESSION['tid']; ?>&&mid=<?php echo base64_encode("410");
?>"><button type="button" class="btn btn-flat btn-success"><i class="fa fa-plus"></i> Make
Deposit</button></a>
<a href="withdraw.php?id=<?php echo $_SESSION['tid']; ?>&&mid=<?php echo base64_encode("410");
?>"><button type="button" class="btn btn-flat btn-success"><i class="fa fa-plus"></i> Withdraw
Money</button></a>
<a href="send_smsloan.php?id=<?php echo $_SESSION['tid']; ?>&&mid=<?php echo
base64_encode("406"); ?>"><button type="button" class="btn btn-flat btn-info"><i class="fa fa-
envelope"></i> Send SMS</button></a>
<hr>
</div>
</div>
</div>
</div>
</div>
<div id="chartdiv2"></div>
</div>
</div>
</div>
END