vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Mark user as a Referrer [v 1.0.1] (https://vborg.vbsupport.ru/showthread.php?t=55651)

Buczilla 07-26-2003 10:00 PM

Mark user as a Referrer [v 1.0.1]
 
I don't know if anyone has been needing a hack like this... but I did, so decided to make it. 90% of the credit for this hack goes to MarkB (his contributor hack), as I don't know any php, so just changed all the variables in his hack. Thanks alot MarkB!!!

What this hack does: It allows you to mark a user as a referrer, so, if a user has referred a bunch of people, or anything, you can select (in the Admin CP - Under Edit User), that they are a referrer... it will then display an image (or whatever you want) in postbit.

You really could edit MarkB's hack to be ANYTHING (as an option) to be displayed in postbit, but if you don't want to edit the php, this is made for you. Please report any bugs in this thread, it should work, but I don't want to be responsible for a messed up board... so PLEASE BACKUP YOUR DATABASE, AND ALL FILES RELATED TO THIS HACK!!!

Also, please click Install if you use this hack! If you need a hack similiar to this, except for something else you want displayed in postbit... let me know, or try to edit the php yourself (like I did :banana: )

Thanks again MarkB!!!

What might come later: Auto-update if user has an AdminCP-Definable number of referrals. I'm gonna need help with this.

Screenshots to follow:

Buczilla 07-27-2003 06:39 AM

The Option to mark a user as a referrer in the Admin CP

Buczilla 07-27-2003 06:40 AM

Postbit:

Please note, the referrer and contributor are completely seperate, and, it doesn't have to be an image (it can be text, flash, anything)

Dean C 07-27-2003 10:21 AM

Did you specifically ask MarkB for permisson :)?

Buczilla 07-27-2003 05:18 PM

Yes I did.

I know how frustrating it is when people use your stuff, without asking :)

Dean C 07-27-2003 05:40 PM

Ok then no problems :)

- miSt

Buczilla 07-27-2003 09:44 PM

:)

esfron 07-29-2003 12:03 AM

It's not working in 2.3.0

In user.php, I don't find ipaddress='".addslashes($aipaddress)." to add ',referrer='$referrer',

in

$DB_site->query("INSERT INTO user (userid,usergroupid,username,password,email,stylei d,parentemail,coppauser,homepa ge,icq,aim,yahoo,signature,adminemail,showemail,in visible,usertitle,customtitle, joindate,cookieuser,daysprune,lastvisit,lastactivi ty,lastpost,posts,timezoneoffs et,emailnotification,receivepm,emailonpm,ipaddress ,pmpopup,options,birthday) VALUES (NULL,'$usergroupid','".addslashes(htmlspecialchar s($ausername))."','".addslashe s(md5($apassword))."','".addslashes(htmlspecialcha rs($email))."','$userstyleid', '".addslashes(htmlspecialchars($parentemail))."',' $coppauser','".addslashes(html specialchars($homepage))."','".addslashes(htmlspec ialchars($icq))."','".addslash es(htmlspecialchars($aim))."','".addslashes(htmlsp ecialchars($yahoo))."','".adds lashes($signature)."','$adminemail','$showemail',' $invisible','".addslashes($use rtitle)."','$customtitle',$joindate,'$cookieuser', '$daysprune',$lastvisit,$lasta ctivity,$lastpost,'$posts','$timezoneoffset','$ema ilnotification','$receivepm',' $emailonpm','".addslashes($aipaddress)."','$pmpopu p','$options','birthday')");

It's not matching in 2.3.0.

Here is my add:

$DB_site->query("INSERT INTO user (userid,usergroupid,username,password,email,stylei d,parentemail,coppauser,homepa ge,icq,aim,yahoo,signature,adminemail,showemail,in visible,usertitle,customtitle, joindate,cookieuser,nosessionhash,daysprune,lastvi sit,lastactivity,lastpost,post s,timezoneoffset,emailnotification,receivepm,email onpm,ipaddress,referrer,pmpopu p,options,birthday) VALUES (NULL,'$usergroupid','".addslashes(htmlspecialchar s($ausername))."','".addslashe s(md5($apassword))."','".addslashes(htmlspecialcha rs($email))."','$userstyleid', '".addslashes(htmlspecialchars($parentemail))."',' $coppauser','".addslashes(html specialchars($homepage))."','".addslashes(htmlspec ialchars($icq))."','".addslash es(htmlspecialchars($aim))."','".addslashes(htmlsp ecialchars($yahoo))."','".adds lashes($signature)."','$adminemail','$showemail',' $invisible','".addslashes($use rtitle)."','$customtitle',$joindate,'$cookieuser', '$nosessionhash','$daysprune', $lastvisit,$lastactivity,$lastpost,'$posts','$time zoneoffset','$emailnotificatio n','$receivepm','$emailonpm','".addslashes($aipadd ress)."','$referrer','$pmpopup ','$options','$birthday')");

esfron 07-30-2003 02:03 AM

Can someone update this hack ?

thx

Buczilla 07-30-2003 05:09 AM

Oops... try this: (Remember, not user.php, but admin/user.php)!!!

In Line Find:

PHP Code:

".addslashes($aipaddress)." 

In line after add:

PHP Code:

',referrer='$referrer', 

That code section should look like this:

PHP Code:

".addslashes($aipaddress)."','$referrer', 


Lemme know if it works please!


This has been updated in the zip file :)


All times are GMT. The time now is 11:01 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.01115 seconds
  • Memory Usage 1,736KB
  • 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
  • (3)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)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