$db = new PDO("mysql:dbname=;host=localhost", "root", "root");
$sql = "INSERT INTO tasks (name, task) VALUES (:name, :task)";
$statement = $db->prepare($sql);
$statement->bindParam(':name', $_POST['name']);
$statement->bindParam(':task', $_POST['task']);
//$statement->execute();
var_dump($statement->execute());