diff options
author | adam <adam@> | 2021-02-11 19:43:06 +0200 |
---|---|---|
committer | adam <adam@> | 2021-02-11 19:43:06 +0200 |
commit | d538c3041c6c7d05a9328ace960838aa194879d9 (patch) | |
tree | 0b070027c9e758ed1783012c43c58070b39595f5 /php/register.php | |
parent | d35678c131d4547cea8b3d9fcc1978dec0d2d903 (diff) | |
parent | f1cd0085cd8dba8b25818fc998d315b28e6c13a5 (diff) | |
download | fileup-d538c3041c6c7d05a9328ace960838aa194879d9.tar.gz |
setting up
Diffstat (limited to 'php/register.php')
-rw-r--r-- | php/register.php | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/php/register.php b/php/register.php index b6b164c..1d31a91 100644 --- a/php/register.php +++ b/php/register.php @@ -8,6 +8,13 @@ $password=$_POST["password"]; $password2=$_POST["password2"]; $email=$_POST["email"]; + +function validate_credentials(string $username,string $email,string $password,string $password2) : bool +{ + return true; +} + + /*check if we are given shady credentials*/ if(!validate_credentials($username,$email,$password,$password2)) { @@ -24,4 +31,8 @@ if($database->register_user($username,$password,$email)) echo "didn't register"; } + +$_SESSION['username'] = $username; +header('Location: /'); + ?> |