aboutsummaryrefslogtreecommitdiffstats
path: root/password.php
diff options
context:
space:
mode:
authorrub <rub@piwigo.org>2006-03-08 23:14:53 +0000
committerrub <rub@piwigo.org>2006-03-08 23:14:53 +0000
commitb263f0c996eac52afc222b99fb1e9bcb6b064d65 (patch)
tree2cb3716ad84764801710483ab7538589c177a6a6 /password.php
parentcba56c06ede13f30483ca587f0c79cb0e4d82aaa (diff)
Step 1 improvement issue 0000301:
o Change status of table #_user_infos o Don't send password to webmaster, guest, generic Next Step: o Functions Check of status o Restricted Access for user generic git-svn-id: http://piwigo.org/svn/trunk@1070 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r--password.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/password.php b/password.php
index 87a568f3c..3a15d270f 100644
--- a/password.php
+++ b/password.php
@@ -69,8 +69,12 @@ SELECT '.$conf['user_fields']['email'].'
SELECT '.$conf['user_fields']['id'].' AS id
, '.$conf['user_fields']['username'].' AS username
, '.$conf['user_fields']['email'].' AS email
- FROM '.USERS_TABLE.'
- WHERE '.$conf['user_fields']['email'].' = \''.$mail_address.'\'
+FROM '.USERS_TABLE.' as u
+ INNER JOIN '.USER_INFOS_TABLE.' AS ui
+ ON u.'.$conf['user_fields']['id'].' = ui.user_id
+WHERE '
+ .$conf['user_fields']['email'].' = \''.$mail_address.'\' AND
+ ui.status not in (\'guest\', \'generic\', \'webmaster\')
;';
$result = pwg_query($query);