vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Miscellaneous Hacks - vS-IP - Sort by Vote Number/Score (https://vborg.vbsupport.ru/showthread.php?t=150146)

Sychev_S 06-19-2007 10:00 PM

vS-IP - Sort by Vote Number/Score
 
This hack requires a working installation of Psionic Vision's Interactive Profiles Script, that can be found here:
https://vborg.vbsupport.ru/showthrea...hreadid=150028

Here is instructions on how to make your memberlist to be sorted by users with highest score/number of votes.
You can see example here:
http://www.tdotzone.com/forums/memberlist.php

/////////////////////Here we go//////////////////////////
Requires:
- 1 file edit
- 1 template edit
///////////////////////////////////////////////////////////

Open your memberlist.php and FIND:

PHP Code:

case 'username':
            
$sqlsort 'user.username';
            break; 

Add UNDER:

PHP Code:

    case 'popular':
            
$sqlsort 'user.iprof_votenum';
            break;
    case 
'vote':
            
$sqlsort 'user.iprof_votetotal / user.iprof_votenum';
            break; 

Save.

In template memberlist ADD (anywhere you wish I have it right after $navbar):

HTML Code:

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


<a rel="nofollow" href="$vboptions[bburl]/memberlist.php?sort=vote&order=desc">Top Members</a>
|
<a rel="nofollow" href="$vboptions[bburl]/memberlist.php?sort=popular&order=desc">Popular Members</a>


 

</td>
</tr>
</table>

<br/>

Save.

Done. This adds a nice bar where your members can sort users by their rating/number of votes.

jedisct1 06-20-2007 08:11 AM

Hello !

Nice work dude.

What is the script you are using in order to display the login/registration form for guest users?

Sychev_S 06-20-2007 12:26 PM

It was custom made.

akanevsky 06-20-2007 01:23 PM

Спасибо что опубликовал. :)
Может быть, стоит отметить эту публикацию как дополнение к моей теме, чтобы она там показывалась.

Shazz 06-20-2007 01:37 PM

Quote:

Originally Posted by Psionic Vision (Post 1272460)
Спасибо что опубликовал. :)
Может быть, стоит отметить эту публикацию как дополнение к моей теме, чтобы она там показывалась.


English :confused:

akanevsky 06-20-2007 02:00 PM

Quote:

Originally Posted by Shazz (Post 1272462)
English :confused:

I thanked, and I said is that he should set this publication to be a mod of the main thread. That's all. :)

hcmagix 06-20-2007 05:01 PM

Quote:

Originally Posted by Shazz (Post 1272462)
English :confused:

Where is the prolem ? :D:D:D
Im from old GDR and we must learn russian at school :D:D:D

Shazz 06-20-2007 06:07 PM

Quote:

Originally Posted by hcmagix (Post 1272591)
Where is the prolem ? :D:D:D
Im from old GDR and we must learn russian at school :D:D:D

Some people aren't smart enough to learn russian :(

FleaBag 06-21-2007 07:44 PM

How did you get the dropdown filter boxes on the right? Would you mind releasing that?

Sychev_S 06-22-2007 05:49 AM

Quote:

Originally Posted by Psionic Vision (Post 1272460)
Спасибо что опубликовал. :)
Может быть, стоит отметить эту публикацию как дополнение к моей теме, чтобы она там показывалась.

Да без вопросов. Ты же всё-таки хозяин. :)


All times are GMT. The time now is 12:08 AM.

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.01458 seconds
  • Memory Usage 1,747KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_html_printable
  • (2)bbcode_php_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete