/[webwml]/newmaint/gpglogin2.wml
ViewVC logotype

Diff of /newmaint/gpglogin2.wml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by tbm, Fri Jul 13 18:44:56 2001 UTC revision 1.3 by weasel, Sun Nov 18 02:30:33 2001 UTC
# Line 17  session_unregister("s_username"); Line 17  session_unregister("s_username");
17      if (! ($db = open_db())) {      if (! ($db = open_db())) {
18        return FALSE;        return FALSE;
19      }      }
20      $sql = "SELECT * FROM people WHERE email = '$login'";      $sql = "SELECT * FROM people2 WHERE email = '$login'";
21      if (! ($result = pg_exec($db, $sql))) {      if (! ($result = pg_exec($db, $sql))) {
22        echo "Problem with query", pg_ErrorMessage($db), "<BR>";        echo "Problem with query", pg_ErrorMessage($db), "<BR>";
23        return FALSE;        return FALSE;
24      }      }
25      if (pg_NumRows($result) == 1) {      if (pg_NumRows($result) == 1) {
26        $row = pg_Fetch_Array($result, 0);        $row = pg_Fetch_Array($result, 0);
27        if (($row["passwd"] == $password) || ($row["passwd"] == "")) {        if ((passwd_verify($row["passwd"], $password)) || ($row["passwd"] == "")) {
28          $s_username = $login;          $s_username = $login;
29          session_register("s_username");          session_register("s_username");
30          return TRUE;          return TRUE;

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

  ViewVC Help
Powered by ViewVC 1.1.5