// Add description as navigation point
ADD_DESCR("admin", basename(__FILE__));
-OPEN_TABLE("100%", "admin_content admin_content_align", "");
if (!empty($_GET['u_id']))
{
- $result_user = SQL_QUERY_ESC("SELECT status, sex, surname, family, email FROM "._MYSQL_PREFIX."_user_data WHERE userid=%s LIMIT 1",
+ $result_user = SQL_QUERY_ESC("SELECT status, gender, surname, family, email FROM "._MYSQL_PREFIX."_user_data WHERE userid=%s LIMIT 1",
array(bigintval($_GET['u_id'])), __FILE__, __LINE__);
$ACT = false;
if (SQL_NUMROWS($result_user) == 1)
{
// User found
- list($status, $sex, $sname, $fname, $email) = SQL_FETCHROW($result_user);
+ list($status, $gender, $sname, $fname, $email) = SQL_FETCHROW($result_user);
SQL_FREERESULT($result_user);
if (empty($_GET['u_id']))
{
// Ok, lock the account!
$result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET status='LOCKED' WHERE userid=%s LIMIT 1",
array(bigintval($_GET['u_id'])), __FILE__, __LINE__);
- if (SQL_AFFECTEDROWS($link, __FILE__, __LINE__) == 1)
+ if (SQL_AFFECTEDROWS() == 1)
{
// Send an email to the user! In later version you can optionally switch this feature off
$msg = LOAD_EMAIL_TEMPLATE("lock-user", $_POST['reason'], bigintval($_GET['u_id']));
// Ok, unlock the account!
$result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET status='CONFIRMED' WHERE userid=%s LIMIT 1",
array(bigintval($_GET['u_id'])), __FILE__, __LINE__);
- if (SQL_AFFECTEDROWS($link, __FILE__, __LINE__) == 1)
+ if (SQL_AFFECTEDROWS() == 1)
{
// Send an email to the user! In later version you can optionally switch this feature off
$msg = LOAD_EMAIL_TEMPLATE("unlock-user", $_POST['reason'], bigintval($_GET['u_id']));
// Account does not exists!
OUTPUT_HTML("<STRONG class=\"admin_failed\">".ADMIN_MEMBER_404_1.$_GET['u_id'].ADMIN_MEMBER_404_2."</STRONG>");
}
-}
- else
-{
+} else {
// List all users
ADD_MEMBER_SELECTION_BOX();
}
-CLOSE_TABLE();
+
//
?>