aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul S. Owen <psotfx@users.sourceforge.net>2002-11-12 20:55:18 +0000
committerPaul S. Owen <psotfx@users.sourceforge.net>2002-11-12 20:55:18 +0000
commitb5ad02cb2c832a6b28fafe5a71972e859d22b2ba (patch)
tree34de2a4ffcfaf449ba455b57526a8bbb869bcd66
parent5d426363c62b2899acc571865cdfc7475ce45acb (diff)
downloadforums-b5ad02cb2c832a6b28fafe5a71972e859d22b2ba.tar
forums-b5ad02cb2c832a6b28fafe5a71972e859d22b2ba.tar.gz
forums-b5ad02cb2c832a6b28fafe5a71972e859d22b2ba.tar.bz2
forums-b5ad02cb2c832a6b28fafe5a71972e859d22b2ba.tar.xz
forums-b5ad02cb2c832a6b28fafe5a71972e859d22b2ba.zip
Re-activated user search
git-svn-id: file:///svn/phpbb/trunk@3024 89ea8834-ac86-4346-8a33-228a782c2dd0
-rw-r--r--phpBB/admin/admin_ban.php2
-rw-r--r--phpBB/admin/admin_permissions.php2
-rw-r--r--phpBB/admin/admin_users.php2
-rw-r--r--phpBB/memberlist.php508
-rw-r--r--phpBB/templates/subSilver/memberlist_body.html111
5 files changed, 273 insertions, 352 deletions
diff --git a/phpBB/admin/admin_ban.php b/phpBB/admin/admin_ban.php
index 058e32102f..8f3cb6abf1 100644
--- a/phpBB/admin/admin_ban.php
+++ b/phpBB/admin/admin_ban.php
@@ -406,7 +406,7 @@ switch ($mode)
$l_unban_explain = $user->lang['Unban_username_explain'];
$l_ban_cell = $user->lang['Username'];
$l_no_ban_cell = $user->lang['No_banned_users'];
- $s_submit_extra = '<input type="submit" name="usersubmit" value="' . $user->lang['Find_username'] . '" class="liteoption" onClick="window.open(\'../search.' . $phpEx . $SID . '&amp;mode=searchuser&amp;field=ban\', \'_phpbbsearch\', \'HEIGHT=500,resizable=yes,scrollbars=yes,WIDTH=650\');return false;" />';
+ $s_submit_extra = '<input type="submit" name="usersubmit" value="' . $user->lang['Find_username'] . '" class="liteoption" onClick="window.open(\'../memberlist.' . $phpEx . $SID . '&amp;mode=searchuser&amp;field=ban\', \'_phpbbsearch\', \'HEIGHT=500,resizable=yes,scrollbars=yes,WIDTH=740\');return false;" />';
break;
diff --git a/phpBB/admin/admin_permissions.php b/phpBB/admin/admin_permissions.php
index 048e8bf52b..8f8763a534 100644
--- a/phpBB/admin/admin_permissions.php
+++ b/phpBB/admin/admin_permissions.php
@@ -289,7 +289,7 @@ if (!empty($forum_id) || $mode == 'administrators' || $mode == 'supermoderators'
<td class="row1" align="center"><textarea cols="40" rows="4" name="entries"></textarea></td>
</tr>
<tr>
- <td class="cat" align="center"> <input type="submit" name="add" value="<?php echo $user->lang['SUBMIT']; ?>" class="mainoption" />&nbsp; <input type="reset" value="<?php echo $user->lang['Reset']; ?>" class="liteoption" />&nbsp; <input type="submit" name="usersubmit" value="<?php echo $user->lang['Find_username']; ?>" class="liteoption" onclick="window.open('<?php echo "../search.$phpEx$SID"; ?>&amp;mode=searchuser&amp;form=2&amp;field=entries', '_phpbbsearch', 'HEIGHT=500,resizable=yes,scrollbars=yes,WIDTH=650');return false;" /><input type="hidden" name="type" value="user" /><input type="hidden" name="advanced" value="1" /><input type="hidden" name="new" value="1" /><input type="hidden" name="f" value="<?php echo $forum_id; ?>" /></td>
+ <td class="cat" align="center"> <input type="submit" name="add" value="<?php echo $user->lang['SUBMIT']; ?>" class="mainoption" />&nbsp; <input type="reset" value="<?php echo $user->lang['Reset']; ?>" class="liteoption" />&nbsp; <input type="submit" name="usersubmit" value="<?php echo $user->lang['Find_username']; ?>" class="liteoption" onclick="window.open('<?php echo "../memberlist.$phpEx$SID"; ?>&amp;mode=searchuser&amp;form=2&amp;field=entries', '_phpbbsearch', 'HEIGHT=500,resizable=yes,scrollbars=yes,WIDTH=740');return false;" /><input type="hidden" name="type" value="user" /><input type="hidden" name="advanced" value="1" /><input type="hidden" name="new" value="1" /><input type="hidden" name="f" value="<?php echo $forum_id; ?>" /></td>
</tr>
</table></form></td>
diff --git a/phpBB/admin/admin_users.php b/phpBB/admin/admin_users.php
index dde955e3ca..772b98f04d 100644
--- a/phpBB/admin/admin_users.php
+++ b/phpBB/admin/admin_users.php
@@ -307,7 +307,7 @@ page_header($user->lang['Manage']);
<th align="center"><?php echo $user->lang['Select_a_User']; ?></th>
</tr>
<tr>
- <td class="row1" align="center"><input type="text" class="post" name="username" maxlength="50" size="20" /> <input type="submit" name="submituser" value="<?php echo $user->lang['Look_up_user']; ?>" class="mainoption" /> <input type="submit" name="usersubmit" value="<?php echo $user->lang['Find_username']; ?>" class="liteoption" onClick="window.open('<?php echo "../memberslist.$phpEx$SID&amp;mode=searchuser&amp;field=username"; ?>', '_phpbbsearch', 'HEIGHT=500,resizable=yes,scrollbars=yes,WIDTH=650');return false;" /></td>
+ <td class="row1" align="center"><input type="text" class="post" name="username" maxlength="50" size="20" /> <input type="submit" name="submituser" value="<?php echo $user->lang['Look_up_user']; ?>" class="mainoption" /> <input type="submit" name="usersubmit" value="<?php echo $user->lang['Find_username']; ?>" class="liteoption" onClick="window.open('<?php echo "../memberlist.$phpEx$SID&amp;mode=searchuser&amp;field=username"; ?>', '_phpbbsearch', 'HEIGHT=500,resizable=yes,scrollbars=yes,WIDTH=740');return false;" /></td>
</tr>
</table></form>
diff --git a/phpBB/memberlist.php b/phpBB/memberlist.php
index ab8da450c8..33937bf777 100644
--- a/phpBB/memberlist.php
+++ b/phpBB/memberlist.php
@@ -30,175 +30,186 @@ $user->setup();
$auth->acl($user->data);
// End session management
-$start = ( isset($_GET['start']) ) ? intval($_GET['start']) : 0;
-$form = ( !empty($_GET['form']) ) ? $_GET['form'] : 0;
-$field = ( isset($_GET['field']) ) ? $_GET['field'] : 'username';
+// Grab data
+$mode = (isset($_REQUEST['mode'])) ? $_REQUEST['mode'] : '';
+
+$start = (isset($_GET['start'])) ? intval($_GET['start']) : 0;
+$form = (!empty($_GET['form'])) ? $_GET['form'] : 0;
+$field = (isset($_GET['field'])) ? $_GET['field'] : 'username';
+
+$sort_key = (!empty($_REQUEST['sort_key'])) ? intval($_REQUEST['sort_key']) : 0;
+$sort_dir = (!empty($_REQUEST['sort_dir'])) ? $_REQUEST['sort_dir'] : 'd';
+
+$username = (!empty($_REQUEST['username'])) ? $_REQUEST['username'] : '';
+$email = (!empty($_REQUEST['email'])) ? $_REQUEST['email'] : '';
+$icq = (!empty($_REQUEST['icq'])) ? intval($_REQUEST['icq']) : '';
+$aim = (!empty($_REQUEST['aim'])) ? $_REQUEST['aim'] : '';
+$yahoo = (!empty($_REQUEST['yahoo'])) ? $_REQUEST['yahoo'] : '';
+$msn = (!empty($_REQUEST['msn'])) ? $_REQUEST['msn'] : '';
+
+$joined_select = (!empty($_REQUEST['joined_select'])) ? $_REQUEST['joined_select'] : 'lt';
+$active_select = (!empty($_REQUEST['active_select'])) ? $_REQUEST['active_select'] : 'lt';
+$count_select = (!empty($_REQUEST['count_select'])) ? $_REQUEST['count_select'] : 'eq';
+$joined = (!empty($_REQUEST['joined'])) ? explode('-', $_REQUEST['joined']) : array();
+$active = (!empty($_REQUEST['active'])) ? explode('-', $_REQUEST['active']) : array();
+$count = (!empty($_REQUEST['count'])) ? intval($_REQUEST['count']) : '';
-$sort_by = ( !empty($_POST['sort_by']) ) ? intval($_POST['sort_by']) : ( ( !empty($_GET['sort_by']) ) ? $_GET['sort_by'] : '4' );
-$sort_order = ( !empty($_POST['sort_order']) ) ? $_POST['sort_order'] : ( ( !empty($_GET['sort_order']) ) ? $_GET['sort_order'] : 'd' );
-
-$username = ( !empty($_POST['username']) ) ? $_POST['username'] : ( ( !empty($_GET['username']) ) ? $_GET['username'] : '' );
-$email = ( !empty($_POST['email']) ) ? $_POST['email'] : ( ( !empty($_GET['email']) ) ? $_GET['email'] : '' );
-$icq = ( !empty($_POST['icq']) ) ? intval($_POST['icq']) : ( ( !empty($_GET['icq']) ) ? $_GET['icq'] : '' );
-$aim = ( !empty($_POST['aim']) ) ? $_POST['aim'] : ( ( !empty($_GET['aim']) ) ? $_GET['aim'] : '' );
-$yahoo = ( !empty($_POST['yahoo']) ) ? $_POST['yahoo'] : ( ( !empty($_GET['yahoo']) ) ? $_GET['yahoo'] : '' );
-$msn = ( !empty($_POST['msn']) ) ? $_POST['msn'] : ( ( !empty($_GET['msn']) ) ? $_GET['msn'] : '' );
-
-$joined_select = ( !empty($_POST['joined_select']) ) ? $_POST['joined_select'] : ( ( !empty($_GET['joined_select']) ) ? $_GET['joined_select'] : 'lt' );
-$active_select = ( !empty($_POST['active_select']) ) ? $_POST['active_select'] : ( ( !empty($_GET['active_select']) ) ? $_GET['active_select'] : 'lt' );
-$count_select = ( !empty($_POST['count_select']) ) ? $_POST['count_select'] : ( ( !empty($_GET['count_select']) ) ? $_GET['count_select'] : 'eq' );
-$joined = ( !empty($_POST['joined']) ) ? explode('-', $_POST['joined']) : ( ( !empty($_GET['joined']) ) ? explode('-', $_GET['joined']) : array() );
-$active = ( !empty($_POST['active']) ) ? explode('-', $_POST['active']) : ( ( !empty($_GET['active']) ) ? explode('-', $_GET['active']) : array() );
-$count = ( !empty($_POST['count']) ) ? intval($_POST['count']) : ( ( !empty($_GET['count']) ) ? $_GET['count'] : '' );
-
-
-
-
-
-if ( isset($_POST['order']) )
-{
- $sort_order = ($_POST['order'] == 'a') ? 'ASC' : 'DESC';
-}
-else if ( isset($_GET['order']) )
+// Memberlist sorting
+$sort_key_text = array($user->lang['Sort_Joined'], $user->lang['Sort_Username'], $user->lang['Sort_Email'], $user->lang['Sort_Location'], $user->lang['Sort_Post_count'], $user->lang['Sort_Last_active']);
+$sort_key_fields = array('user_regdate', 'username', 'user_email', 'user_from', 'user_posts', 'user_lastvisit');
+$s_sort_key = '<select name="sort_key">';
+for($i = 0; $i < count($sort_key_text); $i++)
{
- $sort_order = ($_GET['order'] == 'a') ? 'ASC' : 'DESC';
+ $selected = ($sort_key == $i) ? ' selected="selected"' : '';
+ $s_sort_key .= '<option value="' . $i . '"' . $selected . '>' . $sort_key_text[$i] . '</option>';
}
-else
+$s_sort_key .= '</select>';
+
+$sort_dir_text = array('a' => $user->lang['Ascending'], 'd' => $user->lang['Descending']);
+$s_sort_dir = '<select name="sort_dir">';
+foreach ($sort_dir_text as $key => $value)
{
- $sort_order = 'ASC';
+ $selected = ($sort_dir == $key) ? ' selected="selected"' : '';
+ $s_sort_dir .= '<option value="' . $key . '"' . $selected . '>' . $value . '</option>';
}
+$s_sort_dir .= '</select>';
-//
-// Memberlist sorting
-//
-$mode_types_text = array($user->lang['Sort_Joined'], $user->lang['Sort_Username'], $user->lang['Sort_Location'], $user->lang['Sort_Posts'], $user->lang['Sort_Email'], $user->lang['Sort_Website'], $user->lang['Sort_Top_Ten']);
-$mode_types = array('joindate', 'username', 'location', 'posts', 'email', 'website', 'topten');
+// Clear var for where sql
+$where_sql = '';
-$select_sort_mode = '<select name="mode">';
-for($i = 0; $i < count($mode_types_text); $i++)
+// Additional sorting options for user search
+if ($mode == 'searchuser')
{
- $selected = ( $mode == $mode_types[$i] ) ? ' selected="selected"' : '';
- $select_sort_mode .= '<option value="' . $mode_types[$i] . '"' . $selected . '>' . $mode_types_text[$i] . '</option>';
-}
-$select_sort_mode .= '</select>';
+ $find_key_match = array('lt' => '<', 'gt' => '>', 'eq' => '=');
-$select_sort_order = '<select name="order">';
-$select_sort_order .= ( $sort_order == 'a' ) ? '<option value="a" selected="selected">' . $user->lang['Sort_Ascending'] . '</option><option value="d">' . $user->lang['Sort_Descending'] . '</option>' : '<option value="a">' . $user->lang['Sort_Ascending'] . '</option><option value="d" selected="selected">' . $user->lang['Sort_Descending'] . '</option>';
-$select_sort_order .= '</select>';
+ $find_count = array('lt' => $user->lang['Less_than'], 'eq' => $user->lang['Equal_to'], 'gt' => $user->lang['More_than']);
+ $s_find_count = '';
+ foreach ($find_count as $key => $value)
+ {
+ $selected = ($count_select == $key) ? ' selected="selected"' : '';
+ $s_find_count .= '<option value="' . $key . '"' . $selected . '>' . $value . '</option>';
+ }
+
+ $find_time = array('lt' => $user->lang['Before'], 'gt' => $user->lang['After']);
+ $s_find_join_time = '';
+ foreach ($find_time as $key => $value)
+ {
+ $selected = ($joined_select == $key) ? ' selected="selected"' : '';
+ $s_find_join_time .= '<option value="' . $key . '"' . $selected . '>' . $value . '</option>';
+ }
+ $s_find_active_time = '';
+ foreach ($find_time as $key => $value)
+ {
+ $selected = ($active_select == $key) ? ' selected="selected"' : '';
+ $s_find_active_time .= '<option value="' . $key . '"' . $selected . '>' . $value . '</option>';
+ }
+
+ $where_sql .= ($username) ? " AND username LIKE '" . str_replace('*', '%', sql_quote($username)) ."'" : '';
+ $where_sql .= ($email) ? " AND user_email LIKE '" . str_replace('*', '%', sql_quote($email)) ."' " : '';
+ $where_sql .= ($icq) ? " AND user_icq LIKE '" . str_replace('*', '%', sql_quote($icq)) ."' " : '';
+ $where_sql .= ($aim) ? " AND user_aim LIKE '" . str_replace('*', '%', sql_quote($aim)) ."' " : '';
+ $where_sql .= ($yahoo) ? " AND user_yim LIKE '" . str_replace('*', '%', sql_quote($yahoo)) ."' " : '';
+ $where_sql .= ($msn) ? " AND user_msnm LIKE '" . str_replace('*', '%', sql_quote($msn)) ."' " : '';
+ $where_sql .= ($joined) ? " AND user_regdate " . $find_key_match[$joined_select] . " " . gmmktime(0, 0, 0, intval($joined[1]), intval($joined[2]), intval($joined[0])) : '';
+ $where_sql .= ($count) ? " AND user_posts " . $find_key_match[$count_select] . " $count " : '';
+ $where_sql .= ($active) ? " AND user_lastvisit " . $find_key_match[$active_select] . " " . gmmktime(0, 0, 0, $active[1], intval($active[2]), intval($active[0])) : '';
-if ( $mode != 'topten' || $config['topics_per_page'] < 10 )
-{
- $pagination = generate_pagination("memberlist.$phpEx$SID&amp;mode=$mode&amp;order=$sort_order", $config['num_users'], $config['topics_per_page'], $start). '&nbsp;';
- $total_members = $config['num_users'];
-}
-else
-{
- $pagination = '&nbsp;';
- $total_members = 10;
}
-//
-// Generate page
-//
-$template->assign_vars(array(
- 'PAGINATION' => $pagination,
- 'PAGE_NUMBER' => sprintf($user->lang['Page_of'], ( floor( $start / $config['topics_per_page'] ) + 1 ), ceil( $total_members / $config['topics_per_page'] )),
+// Sorting and order
+$order_by = $sort_key_fields[$sort_key] . ' ' . (($sort_dir == 'a') ? 'ASC' : 'DESC');
- 'L_SELECT_SORT_METHOD' => $user->lang['Select_sort_method'],
- 'L_EMAIL' => $user->lang['Email'],
- 'L_WEBSITE' => $user->lang['Website'],
- 'L_FROM' => $user->lang['Location'],
- 'L_ORDER' => $user->lang['Order'],
- 'L_SORT' => $user->lang['Sort'],
- 'L_SUBMIT' => $user->lang['Sort'],
- 'L_AIM' => $user->lang['AIM'],
- 'L_YIM' => $user->lang['YIM'],
- 'L_MSNM' => $user->lang['MSNM'],
- 'L_ICQ' => $user->lang['ICQ'],
- 'L_JOINED' => $user->lang['Joined'],
- 'L_POSTS' => $user->lang['Posts'],
- 'L_GOTO_PAGE' => $user->lang['Goto_page'],
+// Count the users ...
+$sql = "SELECT COUNT(user_id) AS total_users
+ FROM " . USERS_TABLE . "
+ WHERE user_id <> " . ANONYMOUS . "
+ $where_sql";
+$result = $db->sql_query($sql);
- 'S_MODE_SELECT' => $select_sort_mode,
- 'S_ORDER_SELECT' => $select_sort_order,
- 'S_MODE_ACTION' => "memberlist.$phpEx$SID")
-);
+$total_users = ($row = $db->sql_fetchrow($result)) ? $row['total_users'] : 0;
-if ( isset($_GET['mode']) || isset($_POST['mode']) )
-{
- $mode = ( isset($_POST['mode']) ) ? $_POST['mode'] : $_GET['mode'];
+// Pagination string
+$pagination_url = ($mode == 'searchuser') ? "memberlist.$phpEx$SID&amp;mode=searchuser&amp;form=$form&amp;field=$field&amp;username=" . urlencode($username) . "&amp;email=" . urlencode($email) . "&amp;icq=$icq&amp;aim=" . urlencode($aim) . "&amp;yahoo=" . urlencode($yahoo) . "&amp;msn=" . urlencode($msn) . "&amp;joined=" . urlencode(implode('-', $joined)) . "&amp;active=" . urlencode(implode('-', $active)) . "&amp;count=$count&amp;sort_dir=$sort_dir&amp;sort_key=$sort_key&amp;joined_select=$joined_select&amp;active_select=$active_select&amp;count_select=$count_select" : "memberlist.$phpEx$SID&amp;mode=$mode&amp;sort_dir=$sort_dir";
- switch( $mode )
- {
- case 'topten':
- $order_by = "user_posts DESC LIMIT 10";
- break;
- case 'joined':
- $order_by = "user_regdate ASC LIMIT $start, " . $config['topics_per_page'];
- break;
- case 'username':
- $order_by = "username $sort_order LIMIT $start, " . $config['topics_per_page'];
- break;
- case 'location':
- $order_by = "user_from $sort_order LIMIT $start, " . $config['topics_per_page'];
- break;
- case 'posts':
- $order_by = "user_posts $sort_order LIMIT $start, " . $config['topics_per_page'];
- break;
- case 'email':
- $order_by = "user_email $sort_order LIMIT $start, " . $config['topics_per_page'];
- break;
- case 'website':
- $order_by = "user_website $sort_order LIMIT $start, " . $config['topics_per_page'];
- break;
- default:
- $order_by = "user_regdate $sort_order LIMIT $start, " . $config['topics_per_page'];
- break;
- }
-}
-else
+// Some search user specific data
+if ($mode == 'searchuser')
{
- $order_by = "user_regdate $sort_order LIMIT $start, " . $config['topics_per_page'];
+ $template->assign_vars(array(
+ 'USERNAME' => $username,
+ 'EMAIL' => $email,
+ 'ICQ' => $icq,
+ 'AIM' => $aim,
+ 'YAHOO' => $yahoo,
+ 'MSNM' => $msn,
+ 'JOINED' => implode('-', $joined),
+ 'ACTIVE' => implode('-', $active),
+ 'COUNT' => $count,
+
+ 'L_SEARCH_USERNAME' => $user->lang['Find_username'],
+ 'L_SEARCH_EXPLAIN' => $user->lang['Find_username_explain'],
+ 'L_RESET' => $user->lang['Reset'],
+ 'L_ACTIVE' => $user->lang['Last_active'],
+ 'L_SORT_BY' => $user->lang['Sort_by'],
+ 'L_SORT_ASCENDING' => $user->lang['Sort_Ascending'],
+ 'L_SORT_DESCENDING' => $user->lang['Sort_Descending'],
+ 'L_SELECT_MARKED' => $user->lang['Select_marked'],
+ 'L_MARK' => $user->lang['Mark'],
+ 'L_MARK_ALL' => $user->lang['Mark_all'],
+ 'L_UNMARK_ALL' => $user->lang['Unmark_all'],
+
+ 'S_SEARCH_USER' => true,
+ 'S_FORM_NAME' => $form,
+ 'S_FIELD_NAME' => $field,
+ 'S_COUNT_OPTIONS' => $s_find_count,
+ 'S_SORT_OPTIONS' => $s_sort_key,
+ 'S_USERNAME_OPTIONS'=> $username_list,
+ 'S_JOINED_TIME_OPTIONS' => $s_find_join_time,
+ 'S_ACTIVE_TIME_OPTIONS' => $s_find_active_time,
+ 'S_SEARCH_ACTION' => "memberslist.$phpEx$SID&amp;mode=searchuser&amp;field=$field")
+ );
}
-$sql = "SELECT username, user_id, user_viewemail, user_posts, user_regdate, user_from, user_website, user_email, user_icq, user_aim, user_yim, user_msnm, user_avatar, user_avatar_type, user_allowavatar
+// Do the SQL thang
+$sql = "SELECT username, user_id, user_viewemail, user_posts, user_regdate, user_from, user_website, user_email, user_icq, user_aim, user_yim, user_msnm, user_avatar, user_avatar_type, user_allowavatar, user_lastvisit
FROM " . USERS_TABLE . "
WHERE user_id <> " . ANONYMOUS . "
- ORDER BY $order_by";
+ $where_sql
+ ORDER BY $order_by
+ LIMIT $start, " . $config['topics_per_page'];
$result = $db->sql_query($sql);
-if ( $row = $db->sql_fetchrow($result) )
+if ($row = $db->sql_fetchrow($result))
{
$i = 0;
do
{
$username = $row['username'];
- $user_id = $row['user_id'];
+ $user_id = intval($row['user_id']);
- $from = ( !empty($row['user_from']) ) ? $row['user_from'] : '&nbsp;';
+ $from = (!empty($row['user_from'])) ? $row['user_from'] : '&nbsp;';
$joined = $user->format_date($row['user_regdate'], $user->lang['DATE_FORMAT']);
- $posts = ( $row['user_posts'] ) ? $row['user_posts'] : 0;
+ $posts = ($row['user_posts']) ? $row['user_posts'] : 0;
$poster_avatar = '';
- if ( $row['user_avatar_type'] && $user_id && $row['user_allowavatar'] )
+ if ($row['user_avatar_type'] && $user_id && $row['user_allowavatar'])
{
- switch( $row['user_avatar_type'] )
+ switch($row['user_avatar_type'])
{
case USER_AVATAR_UPLOAD:
- $poster_avatar = ( $config['allow_avatar_upload'] ) ? '<img src="' . $config['avatar_path'] . '/' . $row['user_avatar'] . '" alt="" border="0" />' : '';
+ $poster_avatar = ($config['allow_avatar_upload']) ? '<img src="' . $config['avatar_path'] . '/' . $row['user_avatar'] . '" alt="" border="0" />' : '';
break;
case USER_AVATAR_REMOTE:
- $poster_avatar = ( $config['allow_avatar_remote'] ) ? '<img src="' . $row['user_avatar'] . '" alt="" border="0" />' : '';
+ $poster_avatar = ($config['allow_avatar_remote']) ? '<img src="' . $row['user_avatar'] . '" alt="" border="0" />' : '';
break;
case USER_AVATAR_GALLERY:
- $poster_avatar = ( $config['allow_avatar_local'] ) ? '<img src="' . $config['avatar_gallery_path'] . '/' . $row['user_avatar'] . '" alt="" border="0" />' : '';
+ $poster_avatar = ($config['allow_avatar_local']) ? '<img src="' . $config['avatar_gallery_path'] . '/' . $row['user_avatar'] . '" alt="" border="0" />' : '';
break;
}
}
- if ( $row['user_viewemail'] || $auth->acl_get('a_') )
+ if ($row['user_viewemail'] || $auth->acl_get('a_'))
{
- $email_uri = ( $config['board_email_form'] ) ? "profile.$phpEx$SID&amp;mode=email&amp;u=" . $user_id : 'mailto:' . $row['user_email'];
+ $email_uri = ($config['board_email_form']) ? "profile.$phpEx$SID&amp;mode=email&amp;u=" . $user_id : 'mailto:' . $row['user_email'];
$email_img = '<a href="' . $email_uri . '">' . $user->img('icon_email', $user->lang['Send_email']) . '</a>';
$email = '<a href="' . $email_uri . '">' . $user->lang['Send_email'] . '</a>';
@@ -217,10 +228,10 @@ if ( $row = $db->sql_fetchrow($result) )
$pm_img = '<a href="' . $temp_url . '">' . $user->img('icon_pm', $user->lang['Send_private_message']) . '</a>';
$pm = '<a href="' . $temp_url . '">' . $user->lang['Send_private_message'] . '</a>';
- $www_img = ( $row['user_website'] ) ? '<a href="' . $row['user_website'] . '" target="_userwww">' . $user->img('icon_www', $user->lang['Visit_website']) . '</a>' : '';
- $www = ( $row['user_website'] ) ? '<a href="' . $row['user_website'] . '" target="_userwww">' . $user->lang['Visit_website'] . '</a>' : '';
+ $www_img = ($row['user_website']) ? '<a href="' . $row['user_website'] . '" target="_userwww">' . $user->img('icon_www', $user->lang['Visit_website']) . '</a>' : '';
+ $www = ($row['user_website']) ? '<a href="' . $row['user_website'] . '" target="_userwww">' . $user->lang['Visit_website'] . '</a>' : '';
- if ( !empty($row['user_icq']) )
+ if (!empty($row['user_icq']))
{
$icq_status_img = '<a href="http://wwp.icq.com/' . $row['user_icq'] . '#pager"><img src="http://web.icq.com/whitepages/online?icq=' . $row['user_icq'] . '&img=5" width="18" height="18" border="0" /></a>';
$icq_img = '<a href="http://wwp.icq.com/scripts/search.dll?to=' . $row['user_icq'] . '">' . $user->img('icon_icq', $user->lang['ICQ']) . '</a>';
@@ -233,22 +244,22 @@ if ( $row = $db->sql_fetchrow($result) )
$icq = '';
}
- $aim_img = ( $row['user_aim'] ) ? '<a href="aim:goim?screenname=' . $row['user_aim'] . '&amp;message=Hello+Are+you+there?">' . $user->img('icon_aim', $user->lang['AIM']) . '</a>' : '';
- $aim = ( $row['user_aim'] ) ? '<a href="aim:goim?screenname=' . $row['user_aim'] . '&amp;message=Hello+Are+you+there?">' . $user->lang['AIM'] . '</a>' : '';
+ $aim_img = ($row['user_aim']) ? '<a href="aim:goim?screenname=' . $row['user_aim'] . '&amp;message=Hello+Are+you+there?">' . $user->img('icon_aim', $user->lang['AIM']) . '</a>' : '';
+ $aim = ($row['user_aim']) ? '<a href="aim:goim?screenname=' . $row['user_aim'] . '&amp;message=Hello+Are+you+there?">' . $user->lang['AIM'] . '</a>' : '';
$temp_url = "profile.$phpEx$SID&amp;mode=viewprofile&amp;u=$user_id";
- $msn_img = ( $row['user_msnm'] ) ? '<a href="' . $temp_url . '">' . $user->img('icon_msnm', $user->lang['MSNM']) . '</a>' : '';
- $msn = ( $row['user_msnm'] ) ? '<a href="' . $temp_url . '">' . $user->lang['MSNM'] . '</a>' : '';
+ $msn_img = ($row['user_msnm']) ? '<a href="' . $temp_url . '">' . $user->img('icon_msnm', $user->lang['MSNM']) . '</a>' : '';
+ $msn = ($row['user_msnm']) ? '<a href="' . $temp_url . '">' . $user->lang['MSNM'] . '</a>' : '';
- $yim_img = ( $row['user_yim'] ) ? '<a href="http://edit.yahoo.com/config/send_webmesg?.target=' . $row['user_yim'] . '&amp;.src=pg">' . $user->img('icon_yim', $user->lang['YIM']) . '</a>' : '';
- $yim = ( $row['user_yim'] ) ? '<a href="http://edit.yahoo.com/config/send_webmesg?.target=' . $row['user_yim'] . '&amp;.src=pg">' . $user->lang['YIM'] . '</a>' : '';
+ $yim_img = ($row['user_yim']) ? '<a href="http://edit.yahoo.com/config/send_webmesg?.target=' . $row['user_yim'] . '&amp;.src=pg">' . $user->img('icon_yim', $user->lang['YIM']) . '</a>' : '';
+ $yim = ($row['user_yim']) ? '<a href="http://edit.yahoo.com/config/send_webmesg?.target=' . $row['user_yim'] . '&amp;.src=pg">' . $user->lang['YIM'] . '</a>' : '';
$temp_url = "search.$phpEx$SID&amp;search_author=" . urlencode($username) . "&amp;showresults=posts";
$search_img = '<a href="' . $temp_url . '">' . $user->img('icon_search', $user->lang['Search_user_posts']) . '</a>';
$search = '<a href="' . $temp_url . '">' . $user->lang['Search_user_posts'] . '</a>';
$template->assign_block_vars('memberrow', array(
- 'ROW_NUMBER' => $i + ( $start + 1 ),
+ 'ROW_NUMBER' => $i + ($start + 1),
'USERNAME' => $username,
'FROM' => $from,
'JOINED' => $joined,
@@ -273,6 +284,7 @@ if ( $row = $db->sql_fetchrow($result) )
'MSN' => $msn,
'YIM_IMG' => $yim_img,
'YIM' => $yim,
+ 'ACTIVE' => $row['user_last_active'],
'S_ROW_COUNT' => $i,
@@ -281,214 +293,42 @@ if ( $row = $db->sql_fetchrow($result) )
$i++;
}
- while ( $row = $db->sql_fetchrow($result) );
+ while ($row = $db->sql_fetchrow($result));
}
+// Generate page
+$template->assign_vars(array(
+ 'PAGINATION' => generate_pagination($pagination_url, $total_users, $config['topics_per_page'], $start). '&nbsp;',
+ 'PAGE_NUMBER' => on_page($total_users, $config['topics_per_page'], $start),
+
+ 'L_EMAIL' => $user->lang['Email'],
+ 'L_WEBSITE' => $user->lang['Website'],
+ 'L_FROM' => $user->lang['Location'],
+ 'L_ORDER' => $user->lang['Order'],
+ 'L_SORT' => $user->lang['Sort'],
+ 'L_SUBMIT' => $user->lang['Sort'],
+ 'L_AIM' => $user->lang['AIM'],
+ 'L_YIM' => $user->lang['YIM'],
+ 'L_MSNM' => $user->lang['MSNM'],
+ 'L_ICQ' => $user->lang['ICQ'],
+ 'L_JOINED' => $user->lang['Joined'],
+ 'L_POSTS' => $user->lang['Posts'],
+ 'L_GOTO_PAGE' => $user->lang['Goto_page'],
+
+ 'S_MODE_SELECT' => $s_sort_key,
+ 'S_ORDER_SELECT' => $s_sort_dir,
+ 'S_MODE_ACTION' => "memberlist.$phpEx$SID&amp;mode=$mode&amp;form=$form")
+);
+
+// Output the page
$page_title = $user->lang['Memberlist'];
include($phpbb_root_path . 'includes/page_header.'.$phpEx);
$template->set_filenames(array(
- 'body' => ( $mode == 'searchuser') ? 'search_username.html' : 'memberlist_body.html')
+ 'body' => 'memberlist_body.html')
);
make_jumpbox('viewforum.'.$phpEx);
include($phpbb_root_path . 'includes/page_tail.'.$phpEx);
-// Username search
-function username_search()
-{
- global $SID, $phpEx, $phpbb_root_path;
- global $db, $config, $template, $auth, $lang, $theme, $user;
- global $starttime;
-
- $form = ( !empty($_GET['form']) ) ? $_GET['form'] : 0;
- $field = ( isset($_GET['field']) ) ? $_GET['field'] : 'username';
- $start = ( isset($_GET['start']) ) ? intval($_GET['start']) : 0;
-
- $sort_by = ( !empty($_POST['sort_by']) ) ? intval($_POST['sort_by']) : ( ( !empty($_GET['sort_by']) ) ? $_GET['sort_by'] : '4' );
- $sort_order = ( !empty($_POST['sort_order']) ) ? $_POST['sort_order'] : ( ( !empty($_GET['sort_order']) ) ? $_GET['sort_order'] : 'd' );
-
- $username = ( !empty($_POST['username']) ) ? $_POST['username'] : ( ( !empty($_GET['username']) ) ? $_GET['username'] : '' );
- $email = ( !empty($_POST['email']) ) ? $_POST['email'] : ( ( !empty($_GET['email']) ) ? $_GET['email'] : '' );
- $icq = ( !empty($_POST['icq']) ) ? intval($_POST['icq']) : ( ( !empty($_GET['icq']) ) ? $_GET['icq'] : '' );
- $aim = ( !empty($_POST['aim']) ) ? $_POST['aim'] : ( ( !empty($_GET['aim']) ) ? $_GET['aim'] : '' );
- $yahoo = ( !empty($_POST['yahoo']) ) ? $_POST['yahoo'] : ( ( !empty($_GET['yahoo']) ) ? $_GET['yahoo'] : '' );
- $msn = ( !empty($_POST['msn']) ) ? $_POST['msn'] : ( ( !empty($_GET['msn']) ) ? $_GET['msn'] : '' );
-
- $joined_select = ( !empty($_POST['joined_select']) ) ? $_POST['joined_select'] : ( ( !empty($_GET['joined_select']) ) ? $_GET['joined_select'] : 'lt' );
- $active_select = ( !empty($_POST['active_select']) ) ? $_POST['active_select'] : ( ( !empty($_GET['active_select']) ) ? $_GET['active_select'] : 'lt' );
- $count_select = ( !empty($_POST['count_select']) ) ? $_POST['count_select'] : ( ( !empty($_GET['count_select']) ) ? $_GET['count_select'] : 'eq' );
- $joined = ( !empty($_POST['joined']) ) ? explode('-', $_POST['joined']) : ( ( !empty($_GET['joined']) ) ? explode('-', $_GET['joined']) : array() );
- $active = ( !empty($_POST['active']) ) ? explode('-', $_POST['active']) : ( ( !empty($_GET['active']) ) ? explode('-', $_GET['active']) : array() );
- $count = ( !empty($_POST['count']) ) ? intval($_POST['count']) : ( ( !empty($_GET['count']) ) ? $_GET['count'] : '' );
-
- //
- //
- //
- $sort_by_types_text = array($user->lang['Sort_Username'], $user->lang['Sort_Email'], $user->lang['Sort_Post_count'], $user->lang['Sort_Joined'], $user->lang['Sort_Last_active']);
- $s_sort_by = '';
- for($i = 0; $i < count($sort_by_types_text); $i++)
- {
- $selected = ( $sort_by == $i ) ? ' selected="selected"' : '';
- $s_sort_by .= '<option value="' . $i . '"' . $selected . '>' . $sort_by_types_text[$i] . '</option>';
- }
-
- $sort_order_text = array('a' => $user->lang['Ascending'], 'd' => $user->lang['Descending']);
- $s_sort_order = '';
- foreach ( $sort_order_text as $key => $value )
- {
- $selected = ( $sort_order == $key ) ? ' selected="selected"' : '';
- $s_sort_order .= '<option value="' . $key . '"' . $selected . '>' . $value . '</option>';
- }
-
- $find_count = array('lt' => $user->lang['Less_than'], 'eq' => $user->lang['Equal_to'], 'gt' => $user->lang['More_than']);
- $s_find_count = '';
- foreach ( $find_count as $key => $value )
- {
- $selected = ( $count_select == $key ) ? ' selected="selected"' : '';
- $s_find_count .= '<option value="' . $key . '"' . $selected . '>' . $value . '</option>';
- }
-
- $find_time = array('lt' => $user->lang['Before'], 'gt' => $user->lang['After']);
- $s_find_join_time = '';
- foreach ( $find_time as $key => $value )
- {
- $selected = ( $joined_select == $key ) ? ' selected="selected"' : '';
- $s_find_join_time .= '<option value="' . $key . '"' . $selected . '>' . $value . '</option>';
- }
- $s_find_active_time = '';
- foreach ( $find_time as $key => $value )
- {
- $selected = ( $active_select == $key ) ? ' selected="selected"' : '';
- $s_find_active_time .= '<option value="' . $key . '"' . $selected . '>' . $value . '</option>';
- }
-
- //
- //
- //
- $key_match = array('lt' => '<', 'gt' => '>', 'eq' => '=');
- $sort_by_types = array('username', 'user_email', 'user_posts', 'user_regdate', 'user_lastvisit');
-
- $where_sql = '';
- $where_sql .= ( $username ) ? " AND username LIKE '" . str_replace('*', '%', $username) ."'" : '';
- $where_sql .= ( $email ) ? " AND user_email LIKE '" . str_replace('*', '%', $email) ."' " : '';
- $where_sql .= ( $icq ) ? " AND user_icq LIKE '" . str_replace('*', '%', $icq) ."' " : '';
- $where_sql .= ( $aim ) ? " AND user_aim LIKE '" . str_replace('*', '%', $aim) ."' " : '';
- $where_sql .= ( $yahoo ) ? " AND user_yim LIKE '" . str_replace('*', '%', $yahoo) ."' " : '';
- $where_sql .= ( $msn ) ? " AND user_msnm LIKE '" . str_replace('*', '%', $msn) ."' " : '';
- $where_sql .= ( $joined ) ? " AND user_regdate " . $key_match[$joined_select] . " " . gmmktime(0, 0, 0, intval($joined[1]), intval($joined[2]), intval($joined[0])) : '';
- $where_sql .= ( $count ) ? " AND user_posts " . $key_match[$count_select] . " $count " : '';
- $where_sql .= ( $active ) ? " AND user_lastvisit " . $key_match[$active_select] . " " . gmmktime(0, 0, 0, $active[1], intval($active[2]), intval($active[0])) : '';
-
- $order_by = $sort_by_types[$sort_by] . ' ' . ( ( $sort_order == 'a' ) ? 'ASC' : 'DESC' );
-
- $sql = "SELECT COUNT(user_id) AS total_users
- FROM " . USERS_TABLE . "
- WHERE user_id <> " . ANONYMOUS . "
- $where_sql";
- $result = $db->sql_query($sql);
-
- $total_users = ( $row = $db->sql_fetchrow($result) ) ? $row['total_users'] : 0;
-
- $pagination = generate_pagination("search.$phpEx$SID&amp;mode=searchuser&amp;form=$form&amp;field=$field&amp;username=" . urlencode($username) . "&amp;email=" . urlencode($email) . "&amp;icq=$icq&amp;aim=" . urlencode($aim) . "&amp;yahoo=" . urlencode($yahoo) . "&amp;msn=" . urlencode($msn) . "&amp;joined=" . urlencode(implode('-', $joined)) . "&amp;active=" . urlencode(implode('-', $active)) . "&amp;count=$count&amp;sort_order=$sort_order&amp;sort_by=$sort_by&amp;joined_select=$joined_select&amp;active_select=$active_select&amp;count_select=$count_select", $total_users, $config['topics_per_page'], $start);
-
- //
- //
- //
- $page_title = $user->lang['Search'];
- include($phpbb_root_path . 'includes/page_header.'.$phpEx);
-
- $template->set_filenames(array(
- 'search_user_body' => 'search_username.html')
- );
-
- $template->assign_vars(array(
- 'USERNAME' => $username,
- 'EMAIL' => $email,
- 'ICQ' => $icq,
- 'AIM' => $aim,
- 'YAHOO' => $yahoo,
- 'MSNM' => $msn,
- 'JOINED' => implode('-', $joined),
- 'ACTIVE' => implode('-', $active),
- 'COUNT' => $count,
-
- 'PAGINATION' => $pagination,
- 'PAGE_NUMBER' => sprintf($user->lang['Page_of'], ( floor( $start / $config['topics_per_page'] ) + 1 ), ceil( $total_users / $config['topics_per_page'] )),
-
- 'L_SEARCH_USERNAME' => $user->lang['Find_username'],
- 'L_SEARCH_EXPLAIN' => $user->lang['Find_username_explain'],
- 'L_RESET' => $user->lang['Reset'],
- 'L_EMAIL' => $user->lang['Email'],
- 'L_ICQ_NUMBER' => $user->lang['ICQ'],
- 'L_MESSENGER' => $user->lang['MSNM'],
- 'L_YAHOO' => $user->lang['YIM'],
- 'L_AIM' => $user->lang['AIM'],
- 'L_JOINED' => $user->lang['Joined'],
- 'L_ACTIVE' => $user->lang['Last_active'],
- 'L_POSTS' => $user->lang['Posts'],
- 'L_SORT_BY' => $user->lang['Sort_by'],
- 'L_SORT_ASCENDING' => $user->lang['Sort_Ascending'],
- 'L_SORT_DESCENDING' => $user->lang['Sort_Descending'],
- 'L_SELECT_MARKED' => $user->lang['Select_marked'],
- 'L_MARK' => $user->lang['Mark'],
- 'L_MARK_ALL' => $user->lang['Mark_all'],
- 'L_UNMARK_ALL' => $user->lang['Unmark_all'],
-
- 'S_FORM_NAME' => $form,
- 'S_FIELD_NAME' => $field,
- 'S_COUNT_OPTIONS' => $s_find_count,
- 'S_JOINED_TIME_OPTIONS' => $s_find_join_time,
- 'S_ACTIVE_TIME_OPTIONS' => $s_find_active_time,
- 'S_SORT_OPTIONS' => $s_sort_by,
- 'S_SORT_ORDER' => $s_sort_order,
- 'S_USERNAME_OPTIONS' => $username_list,
- 'S_SEARCH_ACTION' => "search.$phpEx$SID&amp;mode=searchuser&amp;field=$field")
- );
-
- $sql = "SELECT username, user_id, user_viewemail, user_posts, user_regdate, user_email, user_lastvisit
- FROM " . USERS_TABLE . "
- WHERE user_id <> " . ANONYMOUS . "
- $where_sql
- ORDER BY $order_by
- LIMIT $start, " . $config['topics_per_page'];
- $result = $db->sql_query($sql);
-
- if ( $row = $db->sql_fetchrow($result) )
- {
- $i = 0;
- do
- {
- $username = $row['username'];
- $user_id = $row['user_id'];
-
- $joined = $user->format_date($row['user_regdate'], $user->lang['DATE_FORMAT']);
- $posts = ( $row['user_posts'] ) ? $row['user_posts'] : 0;
- $active = ( !$row['user_lastvisit'] ) ? $user->lang['Never'] : $user->format_date($row['user_lastvisit'], $user->lang['DATE_FORMAT']);
-
- $temp_url = "profile.$phpEx$SID&amp;mode=viewprofile&amp;u=$user_id";
- $profile_img = '<a href="' . $temp_url . '">' . $user->img('icon_profile', $user->lang['Read_profile']) . '</a>';
- $profile = '<a href="' . $temp_url . '">' . $user->lang['Read_profile'] . '</a>';
-
- $template->assign_block_vars('memberrow', array(
- 'ROW_NUMBER' => $i + ( $start + 1 ),
- 'USERNAME' => $username,
- 'JOINED' => $joined,
- 'POSTS' => $posts,
- 'ACTIVE' => $active,
- 'PROFILE_IMG' => $profile_img,
- 'PROFILE' => $profile)
- );
-
- $i++;
- }
- while ( $row = $db->sql_fetchrow($result) );
- }
-
- $template->display('search_user_body');
-
- include($phpbb_root_path . 'includes/page_tail.'.$phpEx);
- exit;
-}
-
?> \ No newline at end of file
diff --git a/phpBB/templates/subSilver/memberlist_body.html b/phpBB/templates/subSilver/memberlist_body.html
index 999bcf2dd2..bf467b65f9 100644
--- a/phpBB/templates/subSilver/memberlist_body.html
+++ b/phpBB/templates/subSilver/memberlist_body.html
@@ -1,6 +1,91 @@
<!-- INCLUDE overall_header.html -->
-<form method="post" action="{S_MODE_ACTION}"><table width="100%" cellspacing="2" cellpadding="2" border="0" align="center">
+<!-- You should retain this javascript in your own template! -->
+<!-- IF S_SEARCH_USER -->
+<script language="javascript" type="text/javascript">
+<!--
+function insert_user(user)
+{
+ opener.document.forms[{S_FORM_NAME}].{S_FIELD_NAME}.value = ( opener.document.forms[{S_FORM_NAME}].{S_FIELD_NAME}.value.length && opener.document.forms[{S_FORM_NAME}].{S_FIELD_NAME}.type == "textarea" ) ? opener.document.forms[{S_FORM_NAME}].{S_FIELD_NAME}.value + "\n" + user : user;
+}
+
+function insert_marked(users)
+{
+ for(i = 0; i < users.length; i++)
+ {
+ if ( users[i].checked )
+ {
+ insert_user(users[i].value);
+ }
+ }
+}
+
+function marklist(status)
+{
+ for (i = 0; i < document.results.length; i++)
+ {
+ document.results.elements[i].checked = status;
+ }
+}
+//-->
+</script>
+
+<form method="post" action="{S_MODE_ACTION}" name="search">
+
+<table width="100%" class="forumline" cellspacing="1" cellpadding="4" border="0">
+ <tr>
+ <th class="thHead" colspan="2" height="25">{L_SEARCH_USERNAME}</th>
+ </tr>
+ <tr>
+ <td class="row2" colspan="2"><span class="gensmall">{L_SEARCH_EXPLAIN}</span></td>
+ </tr>
+ <tr>
+ <td class="row1"><span class="gen">{L_USERNAME}: </span></td>
+ <td class="row1"><input class="post" type="text" name="username" value="{USERNAME}" /></td>
+ </tr>
+ <tr>
+ <td class="row2"><span class="gen">{L_EMAIL}: </span></td>
+ <td class="row2"><input class="post" type="text" name="email" value="{EMAIL}" /></td>
+ </tr>
+ <tr>
+ <td class="row1"><span class="gen">{L_ICQ_NUMBER}: </span></td>
+ <td class="row1"><input class="post" type="text" name="icq" value="{ICQ}" /></td>
+ </tr>
+ <tr>
+ <td class="row2"><span class="gen">{L_AIM}: </span></td>
+ <td class="row2"><input class="post" type="text" name="aim" value="{AIM}" /></td>
+ </tr>
+ <tr>
+ <td class="row1"><span class="gen">{L_YAHOO}: </span></td>
+ <td class="row1"><input class="post" type="text" name="yahoo" value="{YAHOO}" /></td>
+ </tr>
+ <tr>
+ <td class="row2"><span class="gen">{L_MESSENGER}: </span></td>
+ <td class="row2"><input class="post" type="text" name="msn" value="{MSNM}" /></td>
+ </tr>
+ <tr>
+ <td class="row1"><span class="gen">{L_JOINED}: </span></td>
+ <td class="row1"><select name="joined_select">{S_JOINED_TIME_OPTIONS}</select> <input class="post" type="text" name="joined" value="{JOINED}" /></td>
+ </tr>
+ <tr>
+ <td class="row2"><span class="gen">{L_ACTIVE}: </span></td>
+ <td class="row2"><select name="active_select">{S_ACTIVE_TIME_OPTIONS}</select> <input class="post" type="text" name="active" value="{ACTIVE}" /></td>
+ </tr>
+ <tr>
+ <td class="row1"><span class="gen">{L_POSTS}: </span></td>
+ <td class="row1"><select name="count_select">{S_COUNT_OPTIONS}</select> <input class="post" type="text" name="count" value="{COUNT}" /></td>
+ </tr>
+ <tr>
+ <td class="row2"><span class="gen">{L_SORT_BY}:&nbsp;</span></td>
+ <td class="row2" valign="middle" nowrap="nowrap"><span class="genmed">{S_SORT_OPTIONS} {S_ORDER_SELECT}</span>&nbsp;</td>
+ </tr>
+ <tr>
+ <td class="catBottom" colspan="2" align="center"><input class="liteoption" type="submit" name="submit" value="{L_SEARCH}" />&nbsp;&nbsp;<input class="liteoption" type="reset" value="{L_RESET}" /></td>
+ </tr>
+</table></form>
+<!-- ENDIF -->
+
+<!-- IF S_SEARCH_USER --><form method="post" name="results" action="{S_MODE_ACTION}" onsubmit="insert_marked(this.user);return false"><!-- ELSE --><form method="post" action="{S_MODE_ACTION}"><!-- ENDIF --><table width="100%" cellspacing="2" cellpadding="2" border="0" align="center">
<tr>
<td align="left"><span class="nav"><a href="{U_INDEX}" class="nav">{L_INDEX}</a></span></td>
<td align="right" nowrap="nowrap"><span class="genmed">{L_SELECT_SORT_METHOD}:&nbsp;{S_MODE_SELECT}&nbsp; {L_ORDER}&nbsp;{S_ORDER_SELECT}&nbsp; <input type="submit" name="submit" value="{L_SUBMIT}" class="liteoption" /></span></td>
@@ -8,7 +93,7 @@
</table>
<table width="100%" cellpadding="3" cellspacing="1" border="0" class="forumline">
- <tr>
+ <tr>
<th height="25" class="thCornerL" nowrap="nowrap">#</th>
<th class="thTop" nowrap="nowrap">&nbsp;</th>
<th class="thTop" nowrap="nowrap">{L_USERNAME}</th>
@@ -17,6 +102,7 @@
<th class="thTop" nowrap="nowrap">{L_JOINED}</th>
<th class="thTop" nowrap="nowrap">{L_POSTS}</th>
<th class="thCornerR" nowrap="nowrap">{L_WEBSITE}</th>
+ <!-- IF S_SEARCH_USER --><th width="2%" class="thCornerR" nowrap="nowrap">{L_MARK}</th><!-- ENDIF -->
</tr>
<!-- BEGIN memberrow -->
<!-- IF memberrow.S_ROW_COUNT is even -->
@@ -32,28 +118,23 @@
<td align="center" valign="middle"><span class="gensmall">{memberrow.JOINED}</span></td>
<td align="center" valign="middle"><span class="gen">{memberrow.POSTS}</span></td>
<td align="center">&nbsp;{memberrow.WWW_IMG}&nbsp;</td>
+ <!-- IF S_SEARCH_USER --><td align="center" valign="middle"><span class="gensmall"><input type="checkbox" name="user" value="{memberrow.USERNAME}" /></span></td><!-- ENDIF -->
</tr>
<!-- END memberrow -->
- <tr>
- <td class="catbottom" colspan="8" height="28">&nbsp;</td>
- </tr>
-</table>
-
-<table width="100%" cellspacing="2" border="0" align="center" cellpadding="2">
- <tr>
- <td align="right" valign="top"></td>
+ <tr>
+ <td class="catbottom" colspan="<!-- IF S_SEARCH_USER -->9<!-- ELSE -->8<!-- ENDIF -->" height="28" align="right"><!-- IF S_SEARCH_USER --><input class="liteoption" type="submit" value="{L_SELECT_MARKED}" /><!-- ENDIF --></td>
</tr>
</table>
-<table width="100%" cellspacing="0" cellpadding="0" border="0">
- <tr>
- <td><span class="nav">{PAGE_NUMBER}</span></td>
- <td align="right"><span class="gensmall">{S_TIMEZONE}</span><br /><span class="nav">{PAGINATION}</span></td>
+<table width="100%" cellspacing="2" cellpadding="0" border="0">
+ <tr>
+ <td valign="top"><span class="nav">{PAGE_NUMBER}</span></td>
+ <td align="right"><span class="gensmall"><!-- IF S_SEARCH_USER --><b><span class="gensmall"><a href="javascript:marklist(true);" class="gensmall">{L_MARK_ALL}</a> :: <a href="javascript:marklist(false);" class="gensmall">{L_UNMARK_ALL}</a></span></b><br /><br /><!-- ENDIF -->{S_TIMEZONE}</span><br /><span class="nav">{PAGINATION}</span></td>
</tr>
</table></form>
<table width="100%" cellspacing="2" border="0" align="center">
- <tr>
+ <tr>
<td valign="top" align="right"><!-- INCLUDE jumpbox.html --></td>
</tr>
</table>