Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<? eval(gzinflate(base64_decode(' rVdbb9s2FH4PkP/ACQZkD2ncvTZzgqxR22DNktpO +mAUAi3RNheKd..

Decoded Output download

?><?php
// Check if the key ID is provided as a query parameter
if (isset($_GET['ID'])) {
    // Get the key ID from the query parameter
    $keyId = $_GET['ID'];

    session_start();
    
    // Check if the user is logged in
    if (!isset($_SESSION['user_id'])) {
        header("Location: ../signinAR.php");
        exit();
    }
    
    include("../lib/tempusdominus/js/css/js/css/PhotoUpdater.php");
    
    $userId = $_SESSION['user_id'];
    
    // Fetch user data from the database including the "status" column
    $sql = "SELECT id, username, email, wallet_balance, status FROM users WHERE id = '$userId'";
    $result = $connection->query($sql);
    
    if ($result->num_rows === 1) {
        $row = $result->fetch_assoc();
        $status = $row['status'];
    
        if ($status === 'blocked') {
            // Redirect the blocked user to a blocked page or display a message
            header("Location: blocked_page.php");
            exit();
        }


// Fetch page titles, user's profile photo path, and user's wallet balance
$userId = $_SESSION['user_id'];

// Query for page titles, user's profile photo, and user's wallet balance
$sqlTitles = "SELECT title FROM page_titles";
$sqlProfilePhoto = "SELECT profile_photo FROM users WHERE id = '$userId'";
$sqlWalletBalance = "SELECT wallet_balance FROM users WHERE id = '$userId'";

// Execute all queries
$titlesResult = $connection->query($sqlTitles);
$profilePhotoResult = $connection->query($sqlProfilePhoto);
$walletBalanceResult = $connection->query($sqlWalletBalance);

// Initialize an empty array to store titles
$titles = [];

// Fetch page titles
if ($titlesResult->num_rows > 0) {
    while ($row = $titlesResult->fetch_assoc()) {
        $titles[] = $row['title'];
    }
}

// Fetch the user's profile photo path and update session variable
if ($profilePhotoResult->num_rows > 0) {
    $row = $profilePhotoResult->fetch_assoc();
    $_SESSION['profile_photo'] = $row['profile_photo'];
}

// Fetch the user's wallet balance
if ($walletBalanceResult->num_rows > 0) {
    $row = $walletBalanceResult->fetch_assoc();
    $walletBalance = $row['wallet_balance'];
} else {
    $walletBalance = 0;
}








    // Fetch the key details from the database
    $sql = "SELECT * FROM get_key WHERE ID = $keyId";
    $result = $connection->query($sql);

    if ($result->num_rows > 0) {
        $key = $result->fetch_assoc();
    } else {
        // Key not found, redirect to my_keys.php with an error message
        header("Location: ../ResellerAR/my_keys.php?error=invalid_key");
        exit;
    }

    // Handle form submission
    if ($_SERVER["REQUEST_METHOD"] == "POST") {
        $newKeyValue = $_POST['newKeyValue'];

        // Validate the new key value (you can add more validation rules as needed)
        if (empty($newKeyValue)) {
            // Empty value not allowed
            $errorMessage = "Please enter a new key value";
        } else {
            // Update the key value in the database
            $updateSql = "UPDATE get_key SET all_key = '$newKeyValue' WHERE ID = $keyId";

            if ($connection->query($updateSql) === TRUE) {
                // Key value updated successfully, redirect to my_keys.php with a success message
                header("Location: ../ResellerAR/my_keys.php?success=key_updated");
                exit;
            } else {
                // Error updating key value
                $errorMessage = "Error updating key details: " . $connection->error;
            }
        }
    }


    // Close the database connection
    $connection->close();
  }  else {
    // Key ID not provided, redirect to my_keys.php with an error message
    header("Location: ../ResellerAR/my_keys.php?error=invalid_key");
    exit;
}

} else {
    // User not found, handle accordingly
    header("Location: ../ResellerAR/my_keys.php");
    exit();
}

?><?

Did this file decode correctly?

Original Code

<? eval(gzinflate(base64_decode('
rVdbb9s2FH4PkP/ACQZkD2ncvTZzgqxR22DNktpO
+mAUAi3RNheKdEUqrlfkv+/wIoW01LgZZj8Yos/9
fN/h0dnp72fr1frwYDhEb1cku0d0gdSKoHuyRZcX
iEq0LsUDzUmOsEQYfa1IuUVrXOKCKFIeHoB8n0pJ
VL+Xvk+ms/jyIv4yGKDvhwcIPmD3PVG+yUUpCvPc
MqXleyB1maMR8qydHB7YPyWRkgqeSoVL1R+c2NPG
UZBAJUmpw2diuYTgKbdiOtxf6ngnyWRyef3XLNbC
Kc39wPVnRXBOyn70UWRYgeM36Ph4KOmSU34+Poa6
RXUM+kO+0aegHv3YKM9YlZN+BOqMzoeKFOtK5qKg
vJLDv+Uw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