name = $_POST['name'];
$user->slug = sluggify($_POST['slug']);
$user->role = $_POST['role'];
$user->hash = generateHash($_POST['password']);
$user->content = $_POST['content'];
$user->write();
header('Location: /admin/users');
exit();
} else {
$user = new User();
echo "
Creating a new user
";
}
?>