Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 08-22-2009, 10:05 PM
Cledus James Cledus James is offline
 
Join Date: Oct 2008
Posts: 79
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Member's List Sort

I have rank image display on my memberlist.php page. Was wondering if there was a way I could sort the members by rank image instead of alphabetical order. The usergroup names I used for the different ranks are already named "01 - Rank 1 through 21 - Rank 21" so if I could just sort the user list based on usergroup I think it would work.

I know this should be possible somehow. Here's a link to my Members List page. And here's a copy of my memberlist template.

Code:
$stylevar[htmldoctype]
<html xmlns="http://www.w3.org/1999/xhtml" dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<head>
$headinclude
	<title>$vboptions[bbtitle] - $vbphrase[members_list]</title>
</head>
<body>
$header
$navbar

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr align="center">
	$letterbits
</tr>
</table>

<if condition="$show['popups'] AND !$show['usergroup']">
<!-- memberlist quick search form -->
<div class="vbmenu_popup" id="memberlist_search_menu" style="display:none">
<form action="memberlist.php?do=getall" method="post">
	<table cellpadding="4" cellspacing="1" border="0">
	<tr>
		<td class="thead">$vbphrase[search_members]</td>
	</tr>
	<tr>
		<td class="vbmenu_option" title="nohilite">
			<input type="hidden" name="s" value="$session[sessionhash]" />
			<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
			<input type="hidden" name="do" value="getall" />
			<input type="text" class="bginput" name="ausername" size="20" value="$ltr" title="$vbphrase[username]" />$gobutton
		</td>
	</tr>
	<if condition="$show['advancedlink']">
	<tr>
		<td class="vbmenu_option"><a href="memberlist.php?$session[sessionurl]do=search">$vbphrase[advanced_search]</a></td>
	</tr>
	</if>
	</table>
</form>
</div>
<!-- / memberlist quick search form -->
</if>

<br />

$spacer_close
$spacer_open

<if condition="$pagenav">
<table cellpadding="0" cellspacing="0" border="0" width="100%" style="margin-bottom:3px">
<tr valign="bottom">
	<td align="$stylevar[right]">$pagenav</td>
</tr>
</table>
</if>

<form action="profile.php?do=deleteusergroups&amp;usergroupid=$usergroupid" method="post">
<input type="hidden" name="do" value="deleteusergroups" />
<input type="hidden" name="s" value="$session[sessionhash]" />
<input type="hidden" name="securitytoken" value="$bbuserinfo[securitytoken]" />
<input type="hidden" name="usergroupid" value="$usergroupid" />

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center" style="border-bottom-width:0px">
<tr>
	<td class="tcat" width="100%">
		<span class="smallfont" style="float:$stylevar[right]">
			<phrase 1="$first" 2="$last" 3="$totalusers">$vbphrase[showing_results_x_to_y_of_z]</phrase>
			<br />
			<!-- <phrase 1="$searchtime">$vbphrase[search_took_x_seconds]</phrase> -->

















		</span>
		<if condition="$show['usergroup']">
		$vbphrase[members_of_usergroup]<span class="normal">: $leadergroup[title]</span>
		<else />
		$vboptions[bbtitle]: $vbphrase[members_list]
		</if>
	</td>
	<if condition="!$show['usergroup']">
	<td class="vbmenu_control" id="memberlist_search"><a href="memberlist.php?$session[sessionurl]do=search">$vbphrase[search_members]</a> <script type="text/javascript"> vbmenu_register("memberlist_search"); </script></td>
	</if>

</tr>
</table>

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tr align="center">
<td class="thead" nowrap="nowrap">Rank</td>
	<td class="thead" align="$stylevar[left]" nowrap="nowrap"><a href="$sorturl<if condition="!$show['sorturlnoargs']">&amp;</if>order=ASC&amp;sort=username&amp;pp=$perpage$usergrouplink">$vbphrase[username]</a> $sortarrow[username]</td>
	<if condition="$show['emailcol']"><td class="thead" nowrap="nowrap">$vbphrase[contact]</td></if>
	<if condition="$show['imicons']"><td class="thead" nowrap="nowrap">$vbphrase[instant_messaging]</td></if>
	<if condition="$show['homepagecol']"><td class="thead" nowrap="nowrap">$vbphrase[home_page]</td></if>
	<if condition="$show['searchcol']"><td class="thead" nowrap="nowrap">$vbphrase[find_posts]</td></if>
	<if condition="$show['datejoinedcol']"><td class="thead" nowrap="nowrap"><a href="$sorturl<if condition="!$show['sorturlnoargs']">&amp;</if>order=ASC&amp;sort=joindate&amp;pp=$perpage$usergrouplink">$vbphrase[join_date]</a> $sortarrow[joindate]</td></if>
	<if condition="$show['postscol']"><td class="thead" nowrap="nowrap"><a href="$sorturl<if condition="!$show['sorturlnoargs']">&amp;</if>order=DESC&amp;sort=posts&amp;pp=$perpage$usergrouplink">$vbphrase[posts]</a> $sortarrow[posts]</td></if>

	<if condition="$show['lastvisitcol']"><td class="thead" nowrap="nowrap"><a href="$sorturl<if condition="!$show['sorturlnoargs']">&amp;</if>order=DESC&amp;sort=lastvisit&amp;pp=$perpage$usergrouplink">$vbphrase[last_visit]</a> $sortarrow[lastvisit]</td></if>
	<if condition="$show['reputationcol']"><td class="thead" nowrap="nowrap"><a href="$sorturl<if condition="!$show['sorturlnoargs']">&amp;</if>order=DESC&amp;sort=reputation&amp;pp=$perpage$usergrouplink">$vbphrase[reputation]</a> $sortarrow[reputation]</td></if>
	<if condition="$show['avatarcol']"><td class="thead" nowrap="nowrap">$vbphrase[avatar]</td></if>
	<if condition="$show['profilepiccol']"><td class="thead" nowrap="nowrap">$vbphrase[profile_picture]</td></if>
	<if condition="$show['birthdaycol']"><td class="thead" nowrap="nowrap">$vbphrase[birthday]</td></if>
	<if condition="$show['agecol']"><td class="thead" nowrap="nowrap"><a href="$sorturl<if condition="!$show['sorturlnoargs']">&amp;</if>order=ASC&amp;sort=age&amp;pp=$perpage$usergrouplink">$vbphrase[age]</a> $sortarrow[age]</td></if>
	<if condition="$show['customfields']">$customfieldsheader</if>
	<if condition="$show['usergroup']"><td class="thead"><input name="allbox" type="checkbox" value="Check All" title="$vbphrase[check_uncheck_all]" onclick="checkall(this.form);" /></td></if>
</tr>
$memberlistbits
<tr>
	<td class="tfoot" colspan="$totalcols" align="$stylevar[right]">
		<span class="smallfont">
		<if condition="$show['usergroup']">
			<input type="submit" class="button" value="$vbphrase[remove_selected_users]" />
		<else />
			<phrase 1="$first" 2="$last" 3="$totalusers">$vbphrase[showing_results_x_to_y_of_z]</phrase>
		</if>
		</span>
	</td>
</tr>
</table>

</form>

<if condition="$pagenav">
<table cellpadding="0" cellspacing="0" border="0" width="100%" style="margin-top:3px">
<tr valign="top">
	<td align="$stylevar[right]">$pagenav</td>
</tr>
</table>
</if>

$spacer_close
$spacer_open

<br />

<table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr>
	<td width="100%">&nbsp;</td>
	<td>$forumjump</td>
</tr>
</table>

$footer

</body>
</html>
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 10:07 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03453 seconds
  • Memory Usage 2,187KB
  • Queries Executed 13 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_code
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete