<?php
// Enable CORS headers
header("Access-Control-Allow-Origin: *");
header("Access-Control-Allow-Methods: GET, POST");
header("Access-Control-Allow-Headers: Content-Type");
require_once 'db.php';
/*
echo 'Mode ====>';
echo $_GET['mode'];
echo '<br>Plan ====>';
echo $_GET['plan'];
echo '<br>Phone ====>';
echo $_GET['phone'];
echo '<br>ID ====>';
echo $_GET['id'];
echo '<br>Plan ====>';
echo $_GET['plan'];
// Query the database to get all active districts
/*
$query = "SELECT * FROM question_cats WHERE status = 'Active'";
$stmt = $pdo->prepare($query);
$stmt->execute();
// Fetch all matching districts
$data = $stmt->fetchAll(PDO::FETCH_ASSOC);
if ($data) {
// If districts are found
$response = [
'success' => true,
'message' => 'Retrieved',
'datas' => $data // Return all districts in an array
];
} else {
// No districts found
$response = [
'success' => false,
'message' => 'No active districts found',
];
}
// Send the response as JSON
header('Content-Type: application/json');
echo json_encode($response);
*/
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Recharge Now</title>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
</head>
<body>
<!-- Top Bar Starts -->
<div class="container-fluid" >
<div class="row">
<div class="col-md-12" style="text-align:center">
<form method="GET" action="recharge_upload.php">
<label style="text-align:left">Recharge Plan</label>
<br>
<input type="text" class="form-control" readonly name="plan_name" value="<?php echo $_GET['plan_name']">
<label style="text-align:left">Recharge Amount</label>
<br>
<input type="text" class="form-control" readonly name="plan_recharge" value="<?php echo $_GET['plan_recharge']">
<label style="text-align:left">Recharge Mode</label>
<br>
<input type="text" class="form-control" readonly name="plan_mode" >
<label style="text-align:left">Recharge Mode</label>
<br>
<button name="submit" style="width:200px; border-radius: 50px" class="btn btn-success">Submit</button>
</form>
</div>
</div>
</div>
</body>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/js/bootstrap.bundle.min.js" integrity="sha384-C6RzsynM9kWDrMNeT87bh95OGNyZPhcTNXj1NW7RuBCsyN/o0jlpcV8Qyq46cDfL" crossorigin="anonymous"></script>
</html>