";
$json = file_get_contents("data/" . $_POST["ts_user"] . ".json");
$jsonD = json_decode($json, true);
if(password_verify($_POST["password"], $jsonD["password"])){
// Initiate page.
session_start();
$_SESSION["ts_user"] = $jsonD["username"];
$_SESSION["ts_points"] = $jsonD["points"];
$_SESSION["email"] = $jsonD["email"];
header("Location: acc.php");
echo "";
} else {
header("Location: index.php?err=2");
echo "";
}
} else {
header("Location: index.php?err=3");
echo "";
}
} else {
}
}