vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Referrers On Forumhome v.1.3 (https://vborg.vbsupport.ru/showthread.php?t=101324)

tnguy3n 11-23-2005 11:22 PM

Quote:

Originally Posted by hIBEES
Great stuff..before I install is there a way it can EXCLUDE admins ??

You can add in the query:
PHP Code:

AND user.usergroupid != 

For multiple groups:
PHP Code:

AND user.usergroupid NOT IN(6,7,8,9


Deimos 11-24-2005 11:15 AM

Great hack, installed aok, but one small problem

On the bar which shows who's the top referrers, i've got this

Quote:

Flutter (22) Queen Mum (12) Epona (6) Tukaram (6) (6)
As you can see, there's 2 (6)'s after "Tukaram", as if there's another user, but it isn't showing their name?

midaph 11-26-2005 06:35 PM

Installed.

Bounce 11-26-2005 08:43 PM

Quote:

Originally Posted by Deimos
Great hack, installed aok, but one small problem

On the bar which shows who's the top referrers, i've got this



As you can see, there's 2 (6)'s after "Tukaram", as if there's another user, but it isn't showing their name?

maybe if you lengthen how many it pulls from the db

// number of top xx referrers to show :ninja:

in the plugin file

Bounce 11-26-2005 08:50 PM

Quote:

Originally Posted by tnguy3n
You can add in the query:
PHP Code:

AND user.usergroupid != 

For multiple groups:
PHP Code:

AND user.usergroupid NOT IN(6,7,8,9


forgive my non knowledge,where does that go in the query :nervous: :disappointed: :rolleyes: :surprised: :surprised:

G-Force 199 11-27-2005 11:28 AM

I got this error :
Database error in vBulletin 3.5.0:

Code:

Invalid SQL:
SELECT COUNT(*) AS totalref, user.username, user.userid, user.usergroupid, usergroup.usergroupid, usergroup.opentag, usergroup.closetag FROM vbb_user AS users LEFT JOIN vbb_user AS user ON (users.referrerid = user.userid) LEFT JOIN vbb_usergroup ON (usergroup.usergroupid = user.usergroupid) WHERE users.referrerid != 0 GROUP BY users.referrerid ORDER BY totalref DESC LIMIT 0,5;

MySQL Error  : Unknown column 'usergroup.usergroupid' in 'field list'
Error Number : 1054
Date        : Sunday, November 27th 2005 @ 08:25:24 PM
Script      : http://localhost/forum/
Referrer    :
IP Address  : 127.0.0.1
Username    : 1st
Classname    : vB_Database


tnguy3n 11-27-2005 03:13 PM

Quote:

Originally Posted by hIBEES
forgive my non knowledge,where does that go in the query :nervous: :disappointed: :rolleyes: :surprised: :surprised:


something like the following:
PHP Code:

$referrals $db->query_read("SELECT COUNT(*) AS totalref, user.username, user.userid, user.usergroupid, usergroup.usergroupid, usergroup.opentag, usergroup.closetag FROM " TABLE_PREFIX "user AS users LEFT JOIN " TABLE_PREFIX "user AS user ON (users.referrerid = user.userid) LEFT JOIN " TABLE_PREFIX "usergroup ON (usergroup.usergroupid = user.usergroupid) WHERE users.referrerid != 0 AND user.usergroupid != 6 GROUP BY users.referrerid ORDER BY totalref DESC LIMIT 0,$num"); 


tnguy3n 11-27-2005 03:16 PM

Quote:

Originally Posted by G-Force 199
I got this error :
Database error in vBulletin 3.5.0:

Code:

Invalid SQL:
SELECT COUNT(*) AS totalref, user.username, user.userid, user.usergroupid, usergroup.usergroupid, usergroup.opentag, usergroup.closetag FROM vbb_user AS users LEFT JOIN vbb_user AS user ON (users.referrerid = user.userid) LEFT JOIN vbb_usergroup ON (usergroup.usergroupid = user.usergroupid) WHERE users.referrerid != 0 GROUP BY users.referrerid ORDER BY totalref DESC LIMIT 0,5;

MySQL Error  : Unknown column 'usergroup.usergroupid' in 'field list'
Error Number : 1054
Date        : Sunday, November 27th 2005 @ 08:25:24 PM
Script      : http://localhost/forum/
Referrer    :
IP Address  : 127.0.0.1
Username    : 1st
Classname    : vB_Database


G-Force 199,
usergroupid is the first field in usergroup table, existing in both vb 3.0.x and vb 3.5.x. Unless you drop the field by accident or conflict with other hacks.

Bounce 11-27-2005 07:40 PM

Quote:

Originally Posted by tnguy3n
something like the following:
PHP Code:

$referrals $db->query_read("SELECT COUNT(*) AS totalref, user.username, user.userid, user.usergroupid, usergroup.usergroupid, usergroup.opentag, usergroup.closetag FROM " TABLE_PREFIX "user AS users LEFT JOIN " TABLE_PREFIX "user AS user ON (users.referrerid = user.userid) LEFT JOIN " TABLE_PREFIX "usergroup ON (usergroup.usergroupid = user.usergroupid) WHERE users.referrerid != 0 AND user.usergroupid != 6 GROUP BY users.referrerid ORDER BY totalref DESC LIMIT 0,$num"); 



thank you sir

[high]* Bounce installed and working 100% :rolleyes:[/high]

Boofo 11-27-2005 08:28 PM

Hey, college boy. How's it going? ;)

Any way to have the number of referrals after each name be clickable with a window and a list of the names? Or maybe take you to another page that has a referral listing of some kind for the site? ;)


All times are GMT. The time now is 06:12 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.01186 seconds
  • Memory Usage 1,760KB
  • 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
  • (2)bbcode_code_printable
  • (6)bbcode_php_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete