PATH: //home/hwyuvbry/public_html/function
FILE_BARU
CREATE
FOLDER_BARU
MKDIR
UPLOAD_FILE
GO
[ .. KEMBALI ]
📄 deposit.php
↓
X
📄 deposit_asli.php
↓
X
📄 deposit_qris.php
↓
X
📄 edit-user.php
↓
X
📄 error_log
↓
X
📄 index.php
↓
X
📄 konfirmasi.php
↓
X
📄 password.php
↓
X
📄 post-chat.php
↓
X
📄 post-reg.php
↓
X
📄 reset-proses.php
↓
X
📄 session.php
↓
X
📄 step-1.php
↓
X
📄 taruhan4d.php
↓
X
📄 taruhancb.php
↓
X
📄 taruhancb2d.php
↓
X
📄 taruhancj.php
↓
X
📄 taruhancn.php
↓
X
📄 taruhandasar.php
↓
X
📄 taruhankembang.php
↓
X
📄 taruhanshio.php
↓
X
📄 taruhansilang.php
↓
X
📄 taruhantengah.php
↓
X
📄 transferBalanceBack.php
↓
X
📄 upload.php
↓
X
📄 withdraw.php
↓
X
SAVING...
BERHASIL DIUBAH!
EDITING: deposit.php
<?php require_once('session.php'); $metode = $_POST['metode']; $nominal = preg_replace('/[^0-9]/','',$_POST['nominal']); $pay_from = $_POST['pay_from']; $catatan = $_POST['catatan']; $postID = intval($_POST['postID']); $kode_unik = substr(str_shuffle("1234567890"),0,3); $kd_transaksi = date('YmdHis').$kode_unik; $totalBayar = (int)$nominal; $created_date = date('Y-m-d H:i:s'); $bukti_transfer = null; /* ========================== CEK / BUAT SALDO USER ========================== */ $cekSaldo = mysqli_query($conn,"SELECT cuid FROM tb_balance WHERE userID='$postID'"); if(mysqli_num_rows($cekSaldo) == 0){ mysqli_query($conn," INSERT INTO tb_balance (userID,active,pending,transfer,payout,created_date) VALUES ('$postID','0','0','0','0',NOW()) "); } /* ========================== UPLOAD BUKTI TRANSFER ========================== */ if(isset($_FILES['bukti_transfer']) && $_FILES['bukti_transfer']['error']==0){ $target_dir = "../upload/bukti/"; if(!is_dir($target_dir)){ mkdir($target_dir,0777,true); } $ext_allowed = ['jpg','jpeg','png','gif','webp']; $file_name = $_FILES['bukti_transfer']['name']; $file_tmp = $_FILES['bukti_transfer']['tmp_name']; $file_size = $_FILES['bukti_transfer']['size']; $file_ext = strtolower(pathinfo($file_name,PATHINFO_EXTENSION)); if(!in_array($file_ext,$ext_allowed)){ echo "<script>alert('Format file tidak didukung');history.back();</script>"; exit(); } if($file_size > 5*1024*1024){ echo "<script>alert('File terlalu besar (Max 5MB)');history.back();</script>"; exit(); } $new_name = time()."_".uniqid().".".$file_ext; $target_file = $target_dir.$new_name; if(move_uploaded_file($file_tmp,$target_file)){ $bukti_transfer = $new_name; } } /* ========================== VALIDASI NOMINAL ========================== */ if($totalBayar < 10000){ header('Location:../m/deposit.php?notif=1'); exit(); } /* ========================== SIMPAN TRANSAKSI ========================== */ mysqli_query($conn," INSERT INTO tb_transaksi (kd_transaksi,date,transaksi,total,saldo,note,gameid,providerID,jenis,metode,pay_from,userID,status) VALUES ('$kd_transaksi','$created_date','Top Up','$totalBayar','0','$bukti_transfer','','0','1','$metode','$pay_from','$postID','0') "); header("Location: ../m/history.php?trxID=$kd_transaksi"); exit(); ?>
SIMPAN PERUBAHAN