diff --git a/addaccounts.php b/addaccounts.php
index 5f861ce..b2ca3ba 100644
--- a/addaccounts.php
+++ b/addaccounts.php
@@ -12,10 +12,21 @@ if (!empty($_POST['accemail'])) {
exit();
}
+if (!empty($_POST['delchar'])) {
+ echo 'removing selected character(s) from selected account
';
+ $delchar = $con->prepare("DELETE FROM gwchars WHERE charid = ? AND accid = ? AND userid = ?");
+ $delchar->bind_param("iii", $_POST['charid'], $_POST['accid'], $_SESSION['userid']);
+ $delchar->execute();
+ $delchar->close();
+ echo 'Need to figure out code to delete stats related to this character still!
';
+ //header ("Refresh:1; url=addacounts.php");
+ //exit();
+}
+
echo '
| Account name |
|---|