$table_name = "detect_spammy_search"; } // echo $userFile . $googleFile . $table_name; $oper = new Operations(); // POST Handler if (isset($_POST["submit"])) { $action = $_POST["submit"]; if ($action == "submit") { $oper->processed($table_name, $_POST["response"], $_POST["id"], $_POST["url"], $_POST["user"]); } else { if ($action == "exit") { $oper->processed($table_name, "TODO", $_POST["id"]); } else { if ($action == "label and skip url") { $oper->processed($table_name, $_POST["response"], $_POST["id"], $_POST["url"], $_POST["user"]); $oper->skipUrl($table_name, $_POST["response"], $_POST["url"]); } } } } // check whether there is more to show $count = $oper->countRows($table_name); if ($count == -1) { $oper->createTableAndLoadComparisonTask($userFile, $googleFile, $table_name); // $oper->createTable($table_name); // $oper->loadComparisonTask($userFile, $googleFile, $table_name); } else { if ($count == 0) { die("The table has no items"); // $oper->loadComparisonTask($userFile, $googleFile, $table_name); // $result = $oper->processing($table_name);