PATH: //proc/thread-self/cwd/kerbau/function
FILE_BARU
CREATE
FOLDER_BARU
MKDIR
UPLOAD_FILE
GO
[ .. KEMBALI ]
📄 add-bank.php
↓
X
📄 add-banner.php
↓
X
📄 add-game.php
↓
X
📄 add-member.php
↓
X
📄 add-post.php
↓
X
📄 add-promo.php
↓
X
📄 add-promosid.php
↓
X
📄 add-slide.php
↓
X
📄 add-user.php
↓
X
📄 api_call_scatter.php
↓
X
📄 api_nexusggr.php
↓
X
📄 api_set_rtp.php
↓
X
📄 bank-status.php
↓
X
📄 banner-status.php
↓
X
📄 banner.php
↓
X
📄 del-backup.php
↓
X
📄 del-bank.php
↓
X
📄 del-banner.php
↓
X
📄 del-post.php
↓
X
📄 del-promosid.php
↓
X
📄 del-slide.php
↓
X
📄 del-user.php
↓
X
📄 delete_qris.php
↓
X
📄 edit-member.php
↓
X
📄 edit-user.php
↓
X
📄 end-session.php
↓
X
📄 error_log
↓
X
📄 getwinner.php
↓
X
📄 getwinner_2.php
↓
X
📄 index.php
↓
X
📄 integapi.php
↓
X
📄 minimal.php
↓
X
📄 nexus.php
↓
X
📄 post-chat.php
↓
X
📄 post-status.php
↓
X
📄 proses-group.php
↓
X
📄 proses_topup-manual.php
↓
X
📄 proses_topup.php
↓
X
📄 proses_withdraw.php
↓
X
📄 qris.php
↓
X
📄 reject_topup.php
↓
X
📄 reject_withdraw.php
↓
X
📄 setting.php
↓
X
📄 slide-status.php
↓
X
📄 social.php
↓
X
📄 topup.php
↓
X
📄 update_qris.php
↓
X
📄 user-game.php
↓
X
📄 user-status.php
↓
X
SAVING...
BERHASIL DIUBAH!
EDITING: end-session.php
<?php require('../session.php'); $externalPlayerId = $_GET['extplayer']; $provider = $_GET['vendor']; $getPlayer = mysqli_query($conn,"SELECT * FROM `tb_ppplayer` WHERE externalPlayerId = '$externalPlayerId' AND status = 1 AND provider = '$provider'") or die(mysqli_error()); $gp = mysqli_fetch_array($getPlayer); $providernya = $gp['provider']; $balance = $gp['balance']; $kode_unik = substr(str_shuffle(1234567890),0,3); $kd_transaksi = date('Ymds').$kode_unik; $requestID = substr(str_shuffle('abcdefghijklmnopqrstuvwxyz123456789'),0,8); $requestIDD = $requestID.date('s'); $created_date = date('Y-m-d H:i:s'); $sql_provider = mysqli_query($conn,"SELECT * FROM `tb_tripayapi` WHERE provider = '$providernya'") or die(mysqli_error()); $sp = mysqli_fetch_array($sql_provider); $urlRequest = $sp['urlRequest']; $gameUrl = $sp['urlResponse']; $secureLogin = $sp['api_key']; //apiKey $secretKey = $sp['secret_key']; //brandID $catatan = $providernya.' Transfer Back'; if($providernya == 'PragmaticPlay'){ $params1 = 'amount=-'.$balance.'&externalPlayerId='.$externalPlayerId.'&externalTransactionId='.$kd_transaksi.'&secureLogin='.$secureLogin.$secretKey; $hashNeed1 = md5($params1); $curl1 = curl_init(); curl_setopt_array($curl1, array( CURLOPT_URL => $urlRequest.'/balance/transfer', CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_POSTFIELDS => "secureLogin=".$secureLogin."&externalPlayerId=".$externalPlayerId."&externalTransactionId=".$kd_transaksi."&amount=-".$balance."&hash=".$hashNeed1, CURLOPT_HTTPHEADER => array( "Content-Type: application/x-www-form-urlencoded", "Cache-Control: no-cache" ), )); $response1 = curl_exec($curl1); //echo $response1; curl_close($curl1); $hasil1 = json_decode($response1, true); if($hasil1['description'] == 'OK'){ $insert_transaksi = mysqli_query($conn,"INSERT INTO `tb_transaksi` (`kd_transaksi`, `date`, `transaksi`, `total`, `saldo`, `note`, `providerID`, `jenis`, `metode`, `pay_from`, `userID`, `status`) VALUES ('$kd_transaksi','$created_date','Transfer','$balance',0, '$catatan', '1','6','0','$providernya','$usersID',1)") or die(mysqli_error()); $updateBalance = mysqli_query($conn,"UPDATE `tb_balance` SET `active` = active + '$balance' WHERE userID = '$usersID'") or die(mysqli_error()); $updatePlayer = mysqli_query($conn,"UPDATE `tb_ppplayer` SET `status` = 0, `balance` = balance - '$balance' WHERE userID = '$usersID' AND provider = '$providernya'") or die(mysqli_error()); $params2 = 'externalPlayerId='.$externalPlayerId.'&secureLogin='.$secureLogin.$secretKey; $hashNeed2 = md5($params2); $curl2 = curl_init(); curl_setopt_array($curl2, array( CURLOPT_URL => $urlRequest.'/game/session/terminate', CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_POSTFIELDS => "secureLogin=".$secureLogin."&externalPlayerId=".$externalPlayerId."&hash=".$hashNeed2, CURLOPT_HTTPHEADER => array( "Content-Type: application/x-www-form-urlencoded", "Cache-Control: no-cache" ), )); $response2 = curl_exec($curl2); //echo $response1; curl_close($curl2); } } else if($providernya == 'Joker'){ $timestamp = time(); $fields = ['Method' => 'WAC', 'Username' => $externalPlayerId, 'Timestamp' => $timestamp, 'RequestID' => $requestID ]; ksort($fields); $signature = urlencode(base64_encode(hash_hmac("sha1", urldecode(http_build_query($fields,'', '&')), $secretKey, TRUE))); $curl = curl_init(); curl_setopt_array($curl, array( CURLOPT_URL => $urlRequest.'?appid='.$secureLogin.'&signature='.$signature, CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_POSTFIELDS => '{"Method":"WAC","Username":"'.$externalPlayerId.'","Timestamp":"'.$timestamp.'","RequestID":"'.$requestIDD.'"}', CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Cache-Control: no-cache" ), )); $response = curl_exec($curl); //echo $response; curl_close($curl); $hasil = json_decode($response, true); $insert_transaksi = mysqli_query($conn,"INSERT INTO `tb_transaksi` (`kd_transaksi`, `date`, `transaksi`, `total`, `saldo`, `note`, `providerID`, `jenis`, `metode`, `pay_from`, `userID`, `status`) VALUES ('$kd_transaksi','$created_date','Transfer','$balance',0, '$catatan', '2','6','0','$providernya','$usersID',1)") or die(mysqli_error()); $updateBalance = mysqli_query($conn,"UPDATE `tb_balance` SET `active` = active + '$balance' WHERE userID = '$usersID'") or die(mysqli_error()); $updatePlayer = mysqli_query($conn,"UPDATE `tb_ppplayer` SET `status` = 0, `balance` = balance - '$balance' WHERE userID = '$usersID' AND provider = '$providernya'") or die(mysqli_error()); $field = ['Method' => 'SO', 'Username' => $externalPlayerId, 'Timestamp' => $timestamp ]; ksort($field); $signature1 = urlencode(base64_encode(hash_hmac("sha1", urldecode(http_build_query($field,'', '&')), $secretKey, TRUE))); $curl1 = curl_init(); curl_setopt_array($curl1, array( CURLOPT_URL => $urlRequest.'?appid='.$secureLogin.'&signature='.$signature1, CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_POSTFIELDS => '{"Method":"WAC","Username":"'.$externalPlayerId.'","Timestamp":"'.$timestamp.'"}', CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Cache-Control: no-cache" ), )); $response1 = curl_exec($curl1); //echo $response; curl_close($curl1); $hasil1 = json_decode($response1, true); } else if($providernya == 'Habanero'){ $curl3 = curl_init(); curl_setopt_array($curl3, array( CURLOPT_URL => $urlRequest.'WithdrawPlayerMoney', CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_POSTFIELDS => '{ "BrandId": "'.$secretKey.'", "APIKey": "'.$secureLogin.'", "Username": "'.$externalPlayerId.'", "password":"Testaja123", "currencycode":"IDR", "Amount": "-'.$balance.'", "WithdrawAll": "true", "RequestId":"'.$kode_unik.'" }', CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Cache-Control: no-cache" ), )); $response3 = curl_exec($curl3); //echo $response1; curl_close($curl3); $hasil3 = json_decode($response3, true); $insert_transaksi = mysqli_query($conn,"INSERT INTO `tb_transaksi` (`kd_transaksi`, `date`, `transaksi`, `total`, `saldo`, `note`, `providerID`, `jenis`, `metode`, `pay_from`, `userID`, `status`) VALUES ('$kd_transaksi','$created_date','Transfer','$balance',0, '$catatan', '3','6','0','$providernya','$usersID',1)") or die(mysqli_error()); $updateBalance = mysqli_query($conn,"UPDATE `tb_balance` SET `active` = active + '$balance' WHERE userID = '$usersID'") or die(mysqli_error()); $updatePlayer = mysqli_query($conn,"UPDATE `tb_ppplayer` SET `status` = 0, `balance` = balance - '$balance' WHERE userID = '$usersID' AND provider = '$providernya'") or die(mysqli_error()); $curl2 = curl_init(); curl_setopt_array($curl2, array( CURLOPT_URL => $urlRequest.'LogoutPlayerRequest', CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 0, CURLOPT_FOLLOWLOCATION => true, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "POST", CURLOPT_POSTFIELDS => '{ "BrandId": "'.$secretKey.'", "APIKey": "'.$secureLogin.'", "Username": "'.$externalPlayerId.'", "password":"Testaja123" }', CURLOPT_HTTPHEADER => array( "Content-Type: application/json", "Cache-Control: no-cache" ), )); $response2 = curl_exec($curl2); //echo $response1; curl_close($curl2); $hasil2 = json_decode($response2, true); } header('Location: ' . $urlweb . '/room.php'); exit(); ?>
SIMPAN PERUBAHAN