<?php
session_start();
if (!isset($_SESSION['username'])) { header("location:login"); exit; }
include '../functions.php';

if (isset($_GET['id'])) {
    $id = (int)$_GET['id'];
    $stmt = $conn->prepare("UPDATE users SET account_status = 'Active' WHERE id = ?");
    $stmt->bind_param("i", $id);
    $stmt->execute();
    $stmt->close();
}
header("location:members");
exit;
