[AppDB] Fix up creating new users
Tony Lambregts
tony_lambregts at telusplanet.net
Mon Jan 10 20:07:44 CST 2005
Change Log: Fix up creating new users. (after deleting username)
Files Changed: include/user.php
-------------- next part --------------
Index: include/user.php
===================================================================
RCS file: /home/wine/appdb/include/user.php,v
retrieving revision 1.24
diff -u -r1.24 user.php
--- include/user.php 11 Jan 2005 00:26:05 -0000 1.24
+++ include/user.php 11 Jan 2005 02:04:47 -0000
@@ -111,23 +111,22 @@
* create a new user
* returns 0 on success and an error msg on failure
*/
- function create($username, $password, $realname, $email, $CVSrelease)
+ function create($sEmail, $sPassword, $sRealname, $sCVSrelease)
{
- $aInsert = compile_insert_string(array( 'username' => $username,
- 'realname' => $realname,
- 'email' => $email,
+ $aInsert = compile_insert_string(array( 'realname' => $sRealname,
+ 'email' => $sEmail,
'status' => 0,
'perm' => 0,
- 'CVSrelease' => $CVSrelease ));
+ 'CVSrelease' => $sCVSrelease ));
$sFields = "({$aInsert['FIELDS']}, `password`, `stamp`, `created`)";
- $sValues = "({$aInsert['VALUES']}, password('".$password."'), NOW(), NOW() )";
+ $sValues = "({$aInsert['VALUES']}, password('".$sPassword."'), NOW(), NOW() )";
if (!query_userdb("INSERT INTO user_list $sFields VALUES $sValues"))
{
return mysql_error();
}
- return $this->restore($username, $password);
+ return $this->restore($sEmail, $sPassword);
}
More information about the wine-patches
mailing list