$suffix = ""; while (pathos_users_getUserByName($userinfo->username . $suffix) != null) { //username already exists if (isset($_POST["update"]) == 1) { if (in_array($userinfo->username, $usersdone)) { $suffix = rand(100, 999); $userinfo->changed = 1; } else { $tmp = pathos_users_getUserByName($userinfo->username . $suffix); $userinfo->id = $tmp->id; break; } } else { $suffix = rand(100, 999); $userinfo->changed = 1; } } $userinfo->username = $userinfo->username . $suffix; $userarray[] = pathos_users_saveUser($userinfo); $usersdone[] = $userinfo->username; } else { $userinfo->linenum = $linenum; $userarray[] = $userinfo; } } $linenum++; } $template = new Template("importer", "_usercsv_display_users"); $template->assign("userarray", $userarray); $template->output(); unlink(BASE . $_POST["filename"]);
# PURPOSE. See the GNU General Public License # for more details. # # You should have received a copy of the GNU # General Public License along with Exponent; if # not, write to: # # Free Software Foundation, Inc., # 59 Temple Place, # Suite 330, # Boston, MA 02111-1307 USA # # $Id: umgr_lockuser.php,v 1.5 2005/04/18 15:33:34 filetreefrog Exp $ ################################################## // Part of the User Management category if (!defined('PATHOS')) { exit(''); } if (pathos_permissions_check('user_management', pathos_core_makeLocation('administrationmodule'))) { if (!defined('SYS_USERS')) { require_once BASE . 'subsystems/users.php'; } $u = pathos_users_getUserById($_GET['id']); if ($u && $u->is_admin == 0 && ($u->is_acting_admin == 0 || $user->is_admin == 1)) { $u->is_locked = $_GET['value']; pathos_users_saveUser($u); } pathos_flow_redirect(); } else { echo SITE_403_HTML; }
# without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR # PURPOSE. See the GNU General Public License # for more details. # # You should have received a copy of the GNU # General Public License along with Exponent; if # not, write to: # # Free Software Foundation, Inc., # 59 Temple Place, # Suite 330, # Boston, MA 02111-1307 USA # # $Id: saveprofile.php,v 1.7 2005/04/18 15:24:22 filetreefrog Exp $ ################################################## if (!defined('PATHOS')) { exit(''); } if ($user) { if (!defined('SYS_USERS')) { require_once 'subsystems/users.php'; } $user = pathos_users_update($_POST, $user); $user = pathos_users_saveUser($user); $user = pathos_users_saveProfileExtensions($_POST, $user, false); $_SESSION[SYS_SESSION_KEY]['user'] = $user; pathos_flow_redirect(); } else { echo SITE_403_HTML; }