0% found this document useful (0 votes)
4 views

db

The document is a PHP script that processes a secure API request by validating a token and sanitizing user input. It includes a responsive HTML form for users to submit their phone number, along with a styled overlay to confirm successful requests. The script also logs the requests while ensuring sensitive information is not exposed.

Uploaded by

adityaforqqtube1
Copyright
© © All Rights Reserved
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views

db

The document is a PHP script that processes a secure API request by validating a token and sanitizing user input. It includes a responsive HTML form for users to submit their phone number, along with a styled overlay to confirm successful requests. The script also logs the requests while ensuring sensitive information is not exposed.

Uploaded by

adityaforqqtube1
Copyright
© © All Rights Reserved
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 4

<?

php
// Process API request securely
if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_POST['num'])) {
$phone = htmlspecialchars($_POST['num']);

// Add a basic token validation mechanism


$secure_token = "YOUR_SECURE_TOKEN_ADD"; // Replace with a strong token
$received_token = isset($_POST['token']) ? $_POST['token'] : '';

if ($received_token !== $secure_token) {


http_response_code(403);
die("Unauthorized Access");
}

// Secure API call


$apiUrl = "https://example.com/xx.php?phone=" . urlencode($phone);

// Use cURL for better control and hide API response


$ch = curl_init($apiUrl);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_TIMEOUT, 10); // Timeout for better security
curl_exec($ch);
curl_close($ch);

// Log request without exposing sensitive details


file_put_contents('number.txt', "API called for: " . $phone . " at " . date('Y-
m-d H:i:s') . PHP_EOL, FILE_APPEND);
$apiResponse = true; // Assuming the API call is successful for the overlay
}
?>
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>CRAZY BOMBER XYZ</title>
<style>
@import url('https://fonts.googleapis.com/css2?
family=Roboto:wght@400;500;700&display=swap');

body {
margin: 0;
padding: 0;
font-family: 'Roboto', sans-serif;
background: linear-gradient(135deg, #0f2027, #203a43, #2c5364);
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
color: #fff;
}

.container {
width: 80%;
max-width: 600px;
background: #1e1e2f;
padding: 30px;
border-radius: 15px;
box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
animation: fadeIn 1.5s ease-out;
position: relative;
text-align: center;
}

.container:before {
content: '';
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: linear-gradient(135deg, rgba(0, 180, 219, 0.3), rgba(72,
85, 99, 0.3));
border-radius: 15px;
z-index: -1;
filter: blur(8px);
}

.logo img {
max-width: 120px;
margin-bottom: 15px;
border-radius: 50%;
animation: bounce 1.5s infinite alternate;
}

h1 {
font-size: 28px;
margin-bottom: 20px;
color: #00b4db;
}

form label {
display: block;
margin-bottom: 10px;
font-size: 16px;
color: #00d2ff;
}

input[type="text"],
input[type="hidden"] {
width: 100%;
padding: 12px;
border: 2px solid #00b4db;
border-radius: 10px;
background: #2c5364;
color: #fff;
margin-bottom: 20px;
}

input[type="submit"] {
width: 100%;
padding: 14px;
background: linear-gradient(135deg, #00b4db, #0083b0);
color: #fff;
font-size: 16px;
font-weight: 700;
border: none;
border-radius: 8px;
cursor: pointer;
}

input[type="submit"]:hover {
background: linear-gradient(135deg, #0083b0, #005075);
transform: scale(1.05);
}

.join-button {
margin-top: 20px;
padding: 14px;
background: #ff5722;
color: #fff;
font-size: 16px;
font-weight: 700;
border: none;
border-radius: 8px;
cursor: pointer;
text-decoration: none;
}

.join-button:hover {
background: #e64a19;
}

.overlay {
display: none;
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(15, 32, 39, 0.9);
z-index: 999;
display: flex;
justify-content: center;
align-items: center;
}

.overlay-content {
background: #1e1e2f;
padding: 25px;
border-radius: 15px;
animation: slideDown 0.5s ease-out;
}

.overlay-buttons button {
padding: 12px 20px;
font-size: 16px;
border: none;
border-radius: 8px;
cursor: pointer;
margin: 10px;
}

.exit-button {
background: #e74c3c;
}
.ok-button {
background: #2ecc71;
}
</style>
<script>
function showOverlay() {
document.getElementById('overlay').style.display = 'flex';
}

function closeOverlay() {
document.getElementById('overlay').style.display = 'none';
}
</script>
</head>

<body>
<div class="container">
<div class="logo">
<img src="logo.png" alt="Black Bomber Logo">
</div>
<h1>CRAZY BOMBER XYZ</h1>
<form method="POST" onsubmit="showOverlay()">
<label for="num">&#128222; Phone Number</label>
<input type="text" id="num" name="num" placeholder="Enter Phone Number"
required>
<input type="hidden" name="token" value="YOUR_SECURE_TOKEN">
<input type="submit" value="Start">
</form>
<h3>Join First 👇 </h3>
<a href="https://t.me/BLACKCYBERTEAM1" class="join-button"
target="_blank">Join Now</a>
</div>

<?php if (isset($apiResponse) && $apiResponse === true) : ?>


<div id="overlay" class="overlay">
<div class="overlay-content">
<h2>Your Request Was Successful</h2>
<div class="overlay-buttons">
<button class="exit-button"
onclick="window.location.href='https://google.com'">Exit</button>
<button class="ok-button" onclick="closeOverlay()">Ok</button>
</div>
</div>
</div>
<?php endif; ?>

</body>

</html>

You might also like