From: Mischa POSLAWSKY Date: Tue, 24 Apr 2018 22:21:59 +0000 (+0200) Subject: login: store user data in /profile directory X-Git-Tag: v2.6~4 X-Git-Url: http://git.shiar.net/minimedit.git/commitdiff_plain/6236e7cb8d0bd38f741d988cc5241a7b37069555 login: store user data in /profile directory Dedicate /login to related pages, avoiding conflicts with user names. --- diff --git a/.gitignore b/.gitignore index 44375b5..a99a8c9 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,5 @@ # link to some ckeditor build (or checkout in a pinch) /ckeditor + +# dynamic user data +/profile diff --git a/auth.inc.php b/auth.inc.php index 48b81fc..4916ab1 100644 --- a/auth.inc.php +++ b/auth.inc.php @@ -22,7 +22,7 @@ function login($inuser, $inpass = NULL) } # find password data by user name - $userdir = 'login/'.strtolower($inuser); + $userdir = 'profile/'.strtolower($inuser); $pwfile = "$userdir/.passwd"; if (!file_exists($pwfile)) return; $usertest = trim(file_get_contents($pwfile)); diff --git a/login.php b/login.php index a5e834f..801ba1f 100644 --- a/login.php +++ b/login.php @@ -17,7 +17,7 @@ elseif (isset($_GET['logout'])) { if (empty($User)) { ob_clean(); - require_once 'login.inc.php'; + require_once 'login/form.inc.php'; $part = ['warn' => $message]; print getoutput($part); return TRUE; diff --git a/login.inc.php b/login/form.inc.php similarity index 100% rename from login.inc.php rename to login/form.inc.php diff --git a/login.html b/login/index.html similarity index 100% rename from login.html rename to login/index.html