// Add description as navigation point
ADD_DESCR("admin", basename(__FILE__));
-OPEN_TABLE("100%", "admin_content admin_content_align", "");
-
$MORE = ", userid"; $colspan = "4"; // 27
if (EXT_IS_ACTIVE("nickname")) { $MORE = ", nickname"; }
// Set base URL
$BASE = "<A href=\"".URL."/modules.php?module=admin";
-$WHERE = " WHERE refid='0'";
+$whereStatement = " WHERE refid='0'";
if (($_GET['letter'] != _ALL2) && ($_GET['letter'] != _OTHERS) && (!empty($_GET['letter'])))
{
// List only persons w
- $WHERE = " WHERE refid='0' AND family LIKE '".$_GET['letter']."%'";
+ $whereStatement = " WHERE refid='0' AND family LIKE '".$_GET['letter']."%'";
}
if ($_GET['sortby'] == "family_name") $_GET['sortby'] = "family";
-$SQL = "SELECT userid, sex, surname, family, email, REMOTE_ADDR, refid, status".$MORE." FROM "._MYSQL_PREFIX."_user_data".$WHERE." ORDER BY ".$_GET['sortby'];
+$SQL = "SELECT userid, gender, surname, family, email, REMOTE_ADDR, refid, status".$MORE." FROM "._MYSQL_PREFIX."_user_data".$whereStatement." ORDER BY ".$_GET['sortby'];
$result_master = SQL_QUERY($SQL, __FILE__, __LINE__);
// Calculate page count (0.5 fixes a bug with page count)
-$PAGES = round(SQL_NUMROWS($result_master) / $CONFIG['user_limit'] + 0.5);
+$PAGES = round(SQL_NUMROWS($result_master) / $_CONFIG['user_limit'] + 0.5);
if (empty($_GET['page'])) $_GET['page'] = "1";
-if (empty($_GET['offset'])) $_GET['offset'] = $CONFIG['user_limit'];
+if (empty($_GET['offset'])) $_GET['offset'] = $_CONFIG['user_limit'];
// Add limitation to SQL string and run him again
$SQL .= " LIMIT ".($_GET['offset'] * $_GET['page'] - $_GET['offset']).", ".$_GET['offset'];
define('__SORT_LINKS', SortLinks($_GET['letter'], $_GET['sortby'], $colspan, true));
if ($PAGES > 1)
{
- define('__PAGE_NAV', ADD_PAGENAV($PAGES, $CONFIG['user_limit'], true, $colspan, true));
+ define('__PAGE_NAV', ADD_PAGENAV($PAGES, $_CONFIG['user_limit'], true, $colspan, true));
}
else
{
}
$SW = 2; $OUT = "";
- while (list($uid, $sex, $sname, $fname, $email, $IP, $ref, $status, $nick) = SQL_FETCHROW($result))
+ while (list($uid, $gender, $sname, $fname, $email, $IP, $ref, $status, $nick) = SQL_FETCHROW($result))
{
if ($ref > 0) $ref = ADMIN_USER_PROFILE_LINK($ref);
$LINKS = TRANSLATE_COMMA(GET_TOTAL_DATA($uid, "user_links", "id", "userid", true));
$content = array(
'sw' => $SW,
'uid' => ADMIN_USER_PROFILE_LINK($uid),
- 'sex' => TRANSLATE_SEX($sex),
+ 'gender' => TRANSLATE_GENDER($gender),
'sname' => $sname,
'fname' => $fname,
'email' => "<A href=\"".CREATE_EMAIL_LINK($email, "user_data")."\">".$email."</A>",
LOAD_TEMPLATE("admin_settings_saved", false, ADMIN_ACCOUNT_NOREFS_404);
}
-CLOSE_TABLE();
//
?>