diff options
author | z0rglub <z0rglub@piwigo.org> | 2003-09-11 20:22:35 +0000 |
---|---|---|
committer | z0rglub <z0rglub@piwigo.org> | 2003-09-11 20:22:35 +0000 |
commit | c2fe5824a6404ed4936bb66013c79ee40c4a72ff (patch) | |
tree | 4d9f8ffa7e3cd1d8efe15bda760783a5a865aa22 /identification.php | |
parent | b6d77d389c7f285683ce234a4d2cb9f56b22fe88 (diff) |
Bug correction : errors were not shown
git-svn-id: http://piwigo.org/svn/trunk@87 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to '')
-rw-r--r-- | identification.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/identification.php b/identification.php index 9d699a1a3..a44cc8917 100644 --- a/identification.php +++ b/identification.php @@ -24,9 +24,9 @@ $errors = array(); if ( isset( $_POST['login'] ) ) { // retrieving the encrypted password of the login submitted - $query = 'select password'; - $query.= ' from '.PREFIX_TABLE.'users'; - $query.= " where username = '".$_POST['login']."';"; + $query = 'SELECT password'; + $query.= ' FROM '.PREFIX_TABLE.'users'; + $query.= " WHERE username = '".$_POST['login']."';"; $row = mysql_fetch_array( mysql_query( $query ) ); if( $row['password'] == md5( $_POST['pass'] ) ) { @@ -61,7 +61,7 @@ $vtp->setGlobalVar( $handle, 'mail_webmaster', $conf['mail_webmaster'] ); $vtp->setGlobalVar( $handle, 'user_template', $user['template'] ); initialize_template(); //-------------------------------------------------------------- errors display -if ( sizeof( $error ) != 0 ) +if ( sizeof( $errors ) != 0 ) { $vtp->addSession( $handle, 'errors' ); foreach ( $errors as $error ) { |