prepare($sql)) { $stmt->bind_param("s", $username); $stmt->execute(); $stmt->bind_result($bio); $stmt->fetch(); $stmt->close(); } // Handle bio update if ($_SERVER["REQUEST_METHOD"] == "POST" && isset($_POST["bio"])) { $new_bio = trim($_POST["bio"]); $update_sql = "UPDATE users SET bio = ? WHERE username = ?"; if ($stmt = $link->prepare($update_sql)) { $stmt->bind_param("ss", $new_bio, $username); $stmt->execute(); $stmt->close(); } header("Location: profile.php"); // Refresh the page to load the new bio exit(); } ?> Profile Page
Profile Picture

About Me

Home Logout