diff --git a/action/tw-unlink.php b/action/tw-unlink.php
new file mode 100644
index 0000000..0cb835d
--- /dev/null
+++ b/action/tw-unlink.php
@@ -0,0 +1,13 @@
+exec("UPDATE users SET
+ tw_oauth_token = '', tw_oauth_verify = ''
+ WHERE id = ". $_SESSION["uid"] . ";");
+ header("Location: /config");
+}
+else echo("You have to be logged in to perform that action");
+?>
+
diff --git a/config.php b/config.php
index a3fb83b..b7c3959 100644
--- a/config.php
+++ b/config.php
@@ -8,9 +8,11 @@ if(!isset($_SESSION["uid"])){
include("include/header.php");
include("include/settings.php");
-
$db = new SQLite3('ask.db');
+$p_user = $db->query("SELECT * FROM users WHERE username = '" . $_GET["q"] . "';")->fetchArray(SQLITE3_ASSOC);
+//var_dump($p_user);
+
?>
@@ -21,21 +23,40 @@ $db = new SQLite3('ask.db');
+
+
Config
+
+
+
Account settings (WIP, doesn't work)
+
+
-
Config
-
-
- For now this section is under construction, but
- I have activated it to log vinculate accounts with
- Twitter.
-
-
+
+
Posting to Twitter
+
+ For now this section is under construction, but
+ I have activated it to log vinculate accounts with
+ Twitter.
+
+
+
querySingle("SELECT tw_oauth_verify FROM users where id = " . $_SESSION["uid"] . ";")){
echo "
Login with Twitter
";
}
-else echo "
Post test tweet";
+else{
+ echo "
Post test tweet
";
+ echo "
";
+ echo "
Unlink account";
+}
?>
-
+