Bug fix in add user

Makes it possible for admin to create users from admin panel
Forum rules
The content in this forum is dated Dec. 21 2005 and can be used as Archive only. This Forum is LOCKED and READ ONLY !

Bug fix in add user

Postby iridium77 on Mon 01. Dec, 2003 01:24

Hej,

I think I've found a bug.
Password modif weren't working (I saw I m not the only one to encounter the prob.


Code: Select all
#
#-----[ OPEN ]------------------------------------------
#
admin/admin_users.php


[...]
Code: Select all
#
#-----[ FIND ]------------------------------------------
#
if ($signature != '')

#
#-----[ BEFORE, ADD ]------------------------------------------
#i
f ($new_user)
{
   //no password given for this new user, create default password
   $password = md5(DEFAULT_PASSWD);
   $passwd_sql = "user_password = '$password', ";
   //send out email notification goes here
}

should be:

Code: Select all
else if ( empty($password) && empty($password_confirm) )
      {
   //no password given for this new user, create default password
   $password = md5(DEFAULT_PASSWD);
   $passwd_sql = "user_password = '$password', ";
   //send out email notification goes here
}


otherwise the password change is not taken in account !
8)
iridium77
Poster
Poster
 
Posts: 1
Joined: Mon 01. Dec, 2003 01:11

Postby Niels on Mon 22. Dec, 2003 01:30

You seam to be right, in pressent version admin may not create a account and at same time change the password to some "custom" password, only the default password are accepted...

I will post a update, witch look almost as your suggested code.
(if a how-to is EM ready, it will mostly be bullet prof, since a machine is more picky than a human. :D)
User avatar
Niels
Poster
Poster
 
Posts: 4390
Joined: Sat 27. Jul, 2002 15:46


Return to Admin add users [2.0.8/EM]

Who is online

Users browsing this forum: No registered users and 1 guest

cron