[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: schooldata.php
<?php include("../functions.php"); if(!isset($_SESSION['thisadmin_Xw211qAAsq4'])){ header("location: login"); } else { if(isset($_POST['search'])){ $s_code = test_input($_POST['school']); $stmt = $con->prepare("Select * from schools where school_code = ?"); $stmt->execute(array($s_code)); $row = $stmt->fetch(); $school_name = $row['school_name']; } ?> <!doctype html> <html lang="en"> <head> <meta charset="utf-8" /> <title>Dashboard | Online Admission Portal</title> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta content="Premium Multipurpose Admin & Dashboard Template" name="description" /> <meta content="Themesbrand" name="author" /> <!-- App favicon --> <!-- <link rel="shortcut icon" href="assets/images/favicon.ico"> --> <!-- plugin css --> <link href="assets/libs/admin-resources/jquery.vectormap/jquery-jvectormap-1.2.2.css" rel="stylesheet" type="text/css" /> <!-- preloader css --> <link rel="stylesheet" href="assets/css/preloader.min.css" type="text/css" /> <!-- Bootstrap Css --> <link href="assets/css/bootstrap.min.css" id="bootstrap-style" rel="stylesheet" type="text/css" /> <!-- Icons Css --> <link href="assets/css/icons.min.css" rel="stylesheet" type="text/css" /> <!-- App Css--> <link href="assets/css/app.min.css" id="app-style" rel="stylesheet" type="text/css" /> <link href="assets/css/bootstrap.min.css" rel="stylesheet" type="text/css" /> <link href="assets/css/icons.min.css" rel="stylesheet" type="text/css" /> <link href="assets/css/theme.min.css" rel="stylesheet" type="text/css" /> <script src="https://code.highcharts.com/highcharts.js"></script> <script src="https://code.highcharts.com/modules/accessibility.js"></script> <style type="text/css"> .highcharts-figure, /*.highcharts-data-table table { min-width: 310px; max-width: 800px; margin: 1em auto; }*/ #container { height: 450px; } .highcharts-data-table table { font-family: Verdana, sans-serif; border-collapse: collapse; border: 1px solid #ebebeb; margin: 10px auto; text-align: center; width: 100%; max-width: 500px; } .highcharts-data-table caption { padding: 1em 0; font-size: 1.2em; color: #555; } .highcharts-data-table th { font-weight: 600; padding: 0.5em; } .highcharts-data-table td, .highcharts-data-table th, .highcharts-data-table caption { padding: 0.5em; } .highcharts-data-table thead tr, .highcharts-data-table tr:nth-child(even) { background: #f8f8f8; } .highcharts-data-table tr:hover { background: #f1f7ff; } .order-card { color: #fff; } .bg-c-blue { background: linear-gradient(45deg,#2e5cb8,#73b4ff); } .bg-c-green { background: linear-gradient(45deg,#2d8659,#59e0c5); } .bg-c-yellow { background: linear-gradient(45deg,#FFB64D,#ffcb80); } .bg-c-red { background: linear-gradient(45deg,#b30000,#b30000); } .bg-c-pink { background: linear-gradient(45deg,#FF5370,#ff869a); } .card { border-radius: 5px; -webkit-box-shadow: 0 1px 2.94px 0.06px rgba(4,26,55,0.16); box-shadow: 0 1px 2.94px 0.06px rgba(4,26,55,0.16); border: none; margin-bottom: 30px; -webkit-transition: all 0.3s ease-in-out; transition: all 0.3s ease-in-out; } .card .card-block { padding: 25px; } .order-card i { font-size: 26px; } .f-left { float: left; } .f-right { float: right; } .highcharts-credits { display: none !important; } </style> </head> <body> <div id="layout-wrapper"> <?php include("includes/header.php");?> <!-- ========== Left Sidebar Start ========== --> <?php include("includes/sidebar.php");?> <div class="main-content"> <div class="page-content"> <div class="container-fluid"> <!-- start page title --> <div class="row"> <div class="col-12"> <div class="page-title-box d-sm-flex align-items-center justify-content-between"> <h4 class="mb-sm-0 font-size-18">School statistics</h4> <div class="page-title-right"> <ol class="breadcrumb m-0"> <li class="breadcrumb-item"><a href="javascript: void(0);">School statistics</a></li> <li class="breadcrumb-item active">School statistics</li> </ol> </div> </div> </div> </div> <!-- end page title --> <div class="row"> <form method="POST" class="d-flex align-items-center w-100"> <!-- Select Dropdown (8 columns width) --> <div class="col-6"> <label for="exampleInputPassword1" class="form-label">School name</label> <select style="width:100%" class="form-control" id="school-select" name="school" required> <option value="">Select School</option> <?php $select_program = mysqli_query($new, "SELECT * FROM schools WHERE user_name = 'Admin' ORDER BY id DESC"); while ($prog = mysqli_fetch_array($select_program)) { ?> <option value="<?php echo $prog['school_code']; ?>"><?php echo $prog['school_name']; ?></option> <?php } ?> </select> </div> <!-- Search Button (4 columns width) --> <div class="col-2"><br /> <button type="submit" name="search" class="btn btn-primary">Search</button> </div> </form> </div> <br /><br /> <div class="row"> <h4>Records statistics for <?php echo $school_name;?></h4> <div class="col-md-4 col-xl-4"> <div class="card bg-c-blue order-card"> <div class="card-block"> <h6 class="m-b-20" style="color:#fff">Placed by CSSPS</h6> <h2 class="text-right"><span style="color:#fff"> </span></h2> <?php $select_css = mysqli_query($new,"SELECT count(aid) as total FROM enrol_generic WHERE s_code = '$s_code'"); if(mysqli_num_rows($select_css) < 1){ $CSSPS = 0; } else { $howmany = mysqli_fetch_array($select_css); $CSSPS = $howmany['total']; } ?> <p>Total : <?php echo $CSSPS;?><br/></p> </div> </div> </div> <div class="col-md-4 col-xl-4"> <div class="card bg-c-green order-card"> <div class="card-block"> <h6 class="m-b-20" style="color:#fff">Completed online Admission </h6> <h2 class="text-right"><span style="color:#fff"> </span></h2> <?php $select_css = mysqli_query($new,"SELECT count(id) as total FROM enrol_details WHERE s_code = '$s_code' and raw_score IS NOT NULL"); if(mysqli_num_rows($select_css) < 1){ $apply = 0; } else { $howmany = mysqli_fetch_array($select_css); $apply = $howmany['total']; } ?> <p>Total : <?php echo $apply;?> <br/> </p> </div> </div> </div> <div class="col-md-4 col-xl-4"> <div class="card bg-c-red order-card"> <div class="card-block"> <h6 class="m-b-20" style="color:#fff">Yet to perform Online Admission</h6> <h2 class="text-right"><span style="color:#fff"> </span></h2> <?php $yettoappy = $CSSPS - $apply; ?> <p>Total : <?php echo $yettoappy;?> <br/></p> </div> </div> </div> <div class="row"> <p>Unit price : 30</p> <div class="col-4"> <p>Total Completed: <?php echo $apply?></p> <p>Total amount: <?php $all = $apply * 30; echo number_format($all,2)?></p> <p>ICT coordinator(5GHS): <?php $ict = $apply * 5; echo number_format($ict,2) ?></p> <p>School Head(7GHS): <?php $head = $apply * 7; echo number_format($head,2)?></p> <p>GES(5GHS): <?php $GES = $apply * 5; echo number_format($GES,2)?></p> <p>System Owner(13GHS): <?php $system = $apply * 13; echo number_format($system,2)?></p> <p>Total: <?php $total1 = $ict+ $head + $GES + $system; echo number_format($total1,2) ?></p> </div> <div class="col-4"> <?php $sql_count = " SELECT COUNT(*) AS total FROM ( SELECT sp.indexNumber FROM stud_payment sp LEFT JOIN enrol_details ed ON sp.indexNumber = ed.index_no WHERE sp.s_code = '$s_code' AND ed.index_no IS NULL GROUP BY sp.indexNumber ) AS sub "; $result = mysqli_query($new, $sql_count); $row = mysqli_fetch_assoc($result); $totalPaidButNotRegistered = $row['total']; ?> <p>Total Paid but Not Registered: <?php echo $totalPaidButNotRegistered; ?></p> <p>Total amount: <?php $all = $totalPaidButNotRegistered * 30; echo number_format($all,2)?></p> <p>ICT coordinator(5GHS): <?php $ict = $totalPaidButNotRegistered * 5; echo number_format($ict,2) ?></p> <p>School Head(7GHS): <?php $head = $totalPaidButNotRegistered * 7; echo number_format($head,2)?></p> <p>GES(5GHS): <?php $GES = $totalPaidButNotRegistered * 5; echo number_format($GES,2)?></p> <p>System Owner(13GHS): <?php $system = $totalPaidButNotRegistered * 13; echo number_format($system,2)?></p> <p>Total: <?php $total1 = $ict+ $head + $GES + $system; echo number_format($total1,2) ?></p> </div> <div class="col-4"> <?php $sql_count = " SELECT COUNT(*) AS total FROM ( SELECT sp.indexNumber FROM stud_payment sp LEFT JOIN enrol_details ed ON sp.indexNumber = ed.index_no WHERE sp.s_code = '$s_code' AND ed.index_no IS NULL GROUP BY sp.indexNumber ) AS sub "; $result = mysqli_query($new, $sql_count); $row = mysqli_fetch_assoc($result); $totalPaidButNotRegistered = $row['total']; ?> <p>All overall total : <?php echo $overall = $totalPaidButNotRegistered + $apply; ?></p> <p>Total amount: <?php $all = $overall * 30; echo number_format($all,2)?></p> <p>ICT coordinator(5GHS): <?php $ict = $overall * 5; echo number_format($ict,2) ?></p> <p>School Head(7GHS): <?php $head = $overall * 7; echo number_format($head,2)?></p> <p>GES(5GHS): <?php $GES = $overall * 5; echo number_format($GES,2)?></p> <p>System Owner(13GHS): <?php $system = $overall * 13; echo number_format($system,2)?></p> <p>Total: <?php $total1 = $ict+ $head + $GES + $system; echo number_format($total1,2) ?></p> </div> </div> </div> <!-- <figure class="highcharts-figure"> <div id="container"></div> </figure> --> </div> </div> <!-- container-fluid --> </div> <!-- End Page-content --> <?php include("includes/footer.php");?> </div> <!-- end main content--> </div> <!-- END layout-wrapper --> <script type="text/javascript"> Highcharts.setOptions({ colors: Highcharts.map(Highcharts.getOptions().colors, function (color) { return { radialGradient: { cx: 0.5, cy: 0.3, r: 0.7 }, stops: [ [0, color], [1, Highcharts.color(color).brighten(-0.3).get('rgb')] // darken ] }; }) }); Highcharts.chart('container', { chart: { type: 'column' }, title: { text: 'TOTAL NUMBER OF STUDENTS', align: 'left' }, xAxis: { categories: ['Total student', 'Total registered', 'Total unregistered'], crosshair: true, accessibility: { description: 'student' } }, tooltip: { headerFormat: '<span style="font-size:10px">{point.key}</span><table>', pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' + '<td style="padding:0"><b>{point.y:.1f}</b></td></tr>', footerFormat: '</table>', shared: true, useHTML: true }, plotOptions: { series: { borderWidth: 0, dataLabels: { enabled: true, format: '{point.y:.1f}' } } }, series: [ { name: 'Total student', data: [<?php $select_chat = mysqli_query($new,"SELECT count(aid) as total FROM enrol_generic WHERE s_code = '$s_code'"); while($howmanyy = mysqli_fetch_array($select_chat)){ $chatToal = $howmanyy['total']; echo "".$chatToal.","; }?>] }, { name: 'Total registered', data: [<?php $select_css = mysqli_query($new,"SELECT count(id) as total FROM enrol_details WHERE s_code = '$s_code'"); while($howmany = mysqli_fetch_array($select_css)){ $apply1 = $howmany['total']; echo "".$apply1.","; } ?>] }, { name: 'Total unregistered', data: [<?php $select_css = mysqli_query($new,"SELECT count(aid) as total FROM enrol_generic LEFT JOIN enrol_details ON enrol_generic.indexNo = enrol_details.index_no WHERE enrol_generic.s_code='$s_code' and enrol_details.index_no IS NULL"); while($howmany = mysqli_fetch_array($select_css)){ $yettoappyy = $howmany['total']; echo "".$yettoappyy.","; } ?>] } ] }); Highcharts.chart('container1', { chart: { type: 'column' }, title: { text: 'TOTAL PAYMENTS', align: 'left' }, xAxis: { categories: ['Count', 'Total amount'], crosshair: true, accessibility: { description: 'Payment' } }, tooltip: { headerFormat: '<span style="font-size:10px">{point.key}</span><table>', pointFormat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' + '<td style="padding:0"><b>{point.y:.1f}</b></td></tr>', footerFormat: '</table>', shared: true, useHTML: true }, plotOptions: { series: { borderWidth: 0, dataLabels: { enabled: true, format: '{point.y:.1f}' } } }, series: [ { name: 'Total Count', data: [<?php $select_count = mysqli_query($new,"SELECT count(pid) as total FROM stud_payment WHERE s_code = '$s_code'"); while($cunt = mysqli_fetch_array($select_count)){ $totalcount = $cunt['total']; echo "".$totalcount.","; }?>] }, { name: 'Total amount', data: [<?php $totalpay = mysqli_query($new,"SELECT sum(amount) as amount FROM stud_payment WHERE s_code = '$s_code'"); while($payment = mysqli_fetch_array($totalpay)){ $money = $payment['amount']; echo "".$money.","; } ?>] } ] }); </script> <!-- Right Sidebar --> <div class="right-bar"> <div data-simplebar class="h-100"> <!-- <div class="rightbar-title d-flex align-items-center p-3"> <h5 class="m-0 me-2">Theme Customizer</h5> <a href="javascript:void(0);" class="right-bar-toggle ms-auto"> <i class="mdi mdi-close noti-icon"></i> </a> </div> --> <!-- Settings --> <hr class="m-0" /> <div class="p-4"> <h6 class="mb-3">Layout</h6> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="layout" id="layout-vertical" value="vertical"> <label class="form-check-label" for="layout-vertical">Vertical</label> </div> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="layout" id="layout-horizontal" value="horizontal"> <label class="form-check-label" for="layout-horizontal">Horizontal</label> </div> <h6 class="mt-4 mb-3 pt-2">Layout Mode</h6> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="layout-mode" id="layout-mode-light" value="light"> <label class="form-check-label" for="layout-mode-light">Light</label> </div> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="layout-mode" id="layout-mode-dark" value="dark"> <label class="form-check-label" for="layout-mode-dark">Dark</label> </div> <h6 class="mt-4 mb-3 pt-2">Layout Width</h6> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="layout-width" id="layout-width-fuild" value="fuild" onchange="document.body.setAttribute('data-layout-size', 'fluid')"> <label class="form-check-label" for="layout-width-fuild">Fluid</label> </div> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="layout-width" id="layout-width-boxed" value="boxed" onchange="document.body.setAttribute('data-layout-size', 'boxed')"> <label class="form-check-label" for="layout-width-boxed">Boxed</label> </div> <h6 class="mt-4 mb-3 pt-2">Layout Position</h6> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="layout-position" id="layout-position-fixed" value="fixed" onchange="document.body.setAttribute('data-layout-scrollable', 'false')"> <label class="form-check-label" for="layout-position-fixed">Fixed</label> </div> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="layout-position" id="layout-position-scrollable" value="scrollable" onchange="document.body.setAttribute('data-layout-scrollable', 'true')"> <label class="form-check-label" for="layout-position-scrollable">Scrollable</label> </div> <h6 class="mt-4 mb-3 pt-2">Topbar Color</h6> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="topbar-color" id="topbar-color-light" value="light" onchange="document.body.setAttribute('data-topbar', 'light')"> <label class="form-check-label" for="topbar-color-light">Light</label> </div> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="topbar-color" id="topbar-color-dark" value="dark" onchange="document.body.setAttribute('data-topbar', 'dark')"> <label class="form-check-label" for="topbar-color-dark">Dark</label> </div> <h6 class="mt-4 mb-3 pt-2 sidebar-setting">Sidebar Size</h6> <div class="form-check sidebar-setting"> <input class="form-check-input" type="radio" name="sidebar-size" id="sidebar-size-default" value="default" onchange="document.body.setAttribute('data-sidebar-size', 'lg')"> <label class="form-check-label" for="sidebar-size-default">Default</label> </div> <div class="form-check sidebar-setting"> <input class="form-check-input" type="radio" name="sidebar-size" id="sidebar-size-compact" value="compact" onchange="document.body.setAttribute('data-sidebar-size', 'md')"> <label class="form-check-label" for="sidebar-size-compact">Compact</label> </div> <div class="form-check sidebar-setting"> <input class="form-check-input" type="radio" name="sidebar-size" id="sidebar-size-small" value="small" onchange="document.body.setAttribute('data-sidebar-size', 'sm')"> <label class="form-check-label" for="sidebar-size-small">Small (Icon View)</label> </div> <h6 class="mt-4 mb-3 pt-2 sidebar-setting">Sidebar Color</h6> <div class="form-check sidebar-setting"> <input class="form-check-input" type="radio" name="sidebar-color" id="sidebar-color-light" value="light" onchange="document.body.setAttribute('data-sidebar', 'light')"> <label class="form-check-label" for="sidebar-color-light">Light</label> </div> <div class="form-check sidebar-setting"> <input class="form-check-input" type="radio" name="sidebar-color" id="sidebar-color-dark" value="dark" onchange="document.body.setAttribute('data-sidebar', 'dark')"> <label class="form-check-label" for="sidebar-color-dark">Dark</label> </div> <div class="form-check sidebar-setting"> <input class="form-check-input" type="radio" name="sidebar-color" id="sidebar-color-brand" value="brand" onchange="document.body.setAttribute('data-sidebar', 'brand')"> <label class="form-check-label" for="sidebar-color-brand">Brand</label> </div> <h6 class="mt-4 mb-3 pt-2">Direction</h6> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="layout-direction" id="layout-direction-ltr" value="ltr"> <label class="form-check-label" for="layout-direction-ltr">LTR</label> </div> <div class="form-check form-check-inline"> <input class="form-check-input" type="radio" name="layout-direction" id="layout-direction-rtl" value="rtl"> <label class="form-check-label" for="layout-direction-rtl">RTL</label> </div> </div> </div> <!-- end slimscroll-menu--> </div> <!-- /Right-bar --> <!-- Right bar overlay--> <div class="rightbar-overlay"></div> <!-- JAVASCRIPT --> <script src="assets/libs/jquery/jquery.min.js"></script> <script src="assets/libs/bootstrap/js/bootstrap.bundle.min.js"></script> <script src="assets/libs/metismenu/metisMenu.min.js"></script> <script src="assets/libs/simplebar/simplebar.min.js"></script> <script src="assets/libs/node-waves/waves.min.js"></script> <script src="assets/libs/feather-icons/feather.min.js"></script> <!-- pace js --> <script src="assets/libs/pace-js/pace.min.js"></script> <!-- apexcharts --> <script src="assets/libs/apexcharts/apexcharts.min.js"></script> <!-- Plugins js--> <script src="assets/libs/admin-resources/jquery.vectormap/jquery-jvectormap-1.2.2.min.js"></script> <script src="assets/libs/admin-resources/jquery.vectormap/maps/jquery-jvectormap-world-mill-en.js"></script> <!-- dashboard init --> <script src="assets/js/pages/dashboard.init.js"></script> <script src="assets/js/app.js"></script> </body> </html> <?php }?>
Save Changes
Cancel / Back
Close ×
Server Info
Hostname: server1.winmanyltd.com
Server IP: 203.161.60.52
PHP Version: 8.3.27
Server Software: Apache
System: Linux server1.winmanyltd.com 4.18.0-553.22.1.el8_10.x86_64 #1 SMP Tue Sep 24 05:16:59 EDT 2024 x86_64
HDD Total: 117.98 GB
HDD Free: 59.81 GB
Domains on IP: N/A (Requires external lookup)
System Features
Safe Mode:
Off
disable_functions:
None
allow_url_fopen:
On
allow_url_include:
Off
magic_quotes_gpc:
Off
register_globals:
Off
open_basedir:
None
cURL:
Enabled
ZipArchive:
Enabled
MySQLi:
Enabled
PDO:
Enabled
wget:
Yes
curl (cmd):
Yes
perl:
Yes
python:
Yes (py3)
gcc:
Yes
pkexec:
Yes
git:
Yes
User Info
Username: eliosofonline
User ID (UID): 1002
Group ID (GID): 1003
Script Owner UID: 1002
Current Dir Owner: 1002