Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Details »»

Version: 1.00, by Admin (Coder) Admin is offline
Developer Last Online: Nov 2024 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 02-03-2002 Last Update: Never Installs: 103
 
No support by the author.

The idea is from SitePoint Forums.

I think a lot of people really want this hack, and I've even seen a released version of it here, but it used cronjobs and stuff like that I'm sure not all of use want to mess with.

So, here's my version of the hack, completely crobjob-less and 100% working.
The hack also includes an easy way for the admins to change the member of the day at any given time. (see note below)
You can see it in action in this board, on the main page in the stats box.

To install this hack download the attached file (memberofday.hack.php), upload to your /admin folder and use vbHacker.

A couple of notes:
  • The member of the day will reset every day at 12:00am server time.
  • It is possible for the admins to re-choose the member of the day at any given time, by adding "?resetmember=1" when visiting index.php. (only logged in admins can use this; for regular users it won't do anything)
  • The only check in the code is to prevent the same member of the day two days in a row. It is possible, however, that the same member will be chosen two days after he was already a member of the month.
  • I don't recommend using this hack on a small forum (with not-so-many members) because of the above.

That's it, have fun.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #152  
Old 08-16-2002, 07:24 AM
NexDog's Avatar
NexDog NexDog is offline
 
Join Date: Mar 2002
Location: Lost in the Nexus
Posts: 388
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

No errors on FireFly's original code. I won't know if this will bomb until the next day......
Reply With Quote
  #153  
Old 08-19-2002, 06:16 AM
NexDog's Avatar
NexDog NexDog is offline
 
Join Date: Mar 2002
Location: Lost in the Nexus
Posts: 388
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Help!

I used:

Code:
WHERE userid<>$daybits[1] AND posts>99
And the same member has been selected 2 days out of 3!!!

Is there a fix?
Reply With Quote
  #154  
Old 08-22-2002, 01:52 PM
NexDog's Avatar
NexDog NexDog is offline
 
Join Date: Mar 2002
Location: Lost in the Nexus
Posts: 388
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

When using:
Code:
WHERE userid<>$daybits[1] AND lastvisit>".time()-(86400*14)."
I get:
Quote:
Fatal error: Call to undefined function: phperror_reporting() in /var/www/vhosts/hostnexus.com/httpdocs/forum/index.php on line 1
Reply With Quote
  #155  
Old 09-21-2002, 10:18 AM
a43079's Avatar
a43079 a43079 is offline
 
Join Date: Aug 2002
Posts: 68
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

does this work with 2.2.7
Reply With Quote
  #156  
Old 10-16-2002, 05:19 AM
DarkDraco07's Avatar
DarkDraco07 DarkDraco07 is offline
 
Join Date: Apr 2002
Posts: 414
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

problem on newer forums i think. when i enter the query into my database it doesnt save. like, usually if i enter a query twice it says that there is a duplicate column but not for the query here. when i have the hack installed i get an sql error because of this. it there an alternative query to run?
Reply With Quote
  #157  
Old 10-27-2002, 04:15 PM
DarkDraco07's Avatar
DarkDraco07 DarkDraco07 is offline
 
Join Date: Apr 2002
Posts: 414
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

can anyone help?
Reply With Quote
  #158  
Old 11-23-2002, 02:50 AM
javogevp javogevp is offline
 
Join Date: Oct 2002
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hey dude!
do u know if this hack may be modified for giving some credits for "the Lesane´s Store Hack". But if the guy dosnt log in i that day where he was selected for the member of the day he dost win ay money???
please help, i dunno much about programing
Reply With Quote
  #159  
Old 12-15-2002, 09:01 PM
PsyBlast PsyBlast is offline
 
Join Date: Dec 2002
Location: Fayetteville, NC!!!!!!!
Posts: 43
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

whenever I upload the file to the admin folder and run vbhacker.php it doesnt come up, I have refreshed it about 20 times, I have the newest version of vbhacker also.
Reply With Quote
  #160  
Old 01-25-2003, 04:08 AM
Mike Gaidin's Avatar
Mike Gaidin Mike Gaidin is offline
 
Join Date: Oct 2001
Location: Michigan
Posts: 247
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I installed this but it only shows the same two people every other day. I used the text file provided by vbhacker to install it. Are there known issues with this?
Reply With Quote
  #161  
Old 01-25-2003, 04:08 AM
Mike Gaidin's Avatar
Mike Gaidin Mike Gaidin is offline
 
Join Date: Oct 2001
Location: Michigan
Posts: 247
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I installed this but it only shows the same two people every other day. I used the text file provided by vbhacker to install it. Are there known issues with this?
Reply With Quote
  #162  
Old 02-15-2003, 09:45 PM
SouledOut SouledOut is offline
 
Join Date: Nov 2002
Posts: 23
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

ok, now I'm running into some problems, lol. I don't have the MySQL access to the directory, so it's a coding problem (vBHacker added the query correctly, I wish all hacks where like this) anyway, it tells me it can't find
Code:
$permissions=getpermissions();
if (!$permissions['canview']) {
    show_nopermission();
}
yet its on line 10 of index.php on vb2.2.8. I chose not to modify templates, because they use a modded design, and layout wise it belongs in the header. Anyway, I've done everything I'm supposed to, but vBHacker still won't reconize the changes! I found the only instance of the code, and added the code after ('require global.php') and no, the varible part isn't there twice. I just either A) want to get this thing working, or B) get vBHacker to work right. I'll try deleting the .hack.php file to get vBhacker to work again, and add the template manually and see what happens. Since everything is // ed out, I don't think it'll effect index.php.
Reply With Quote
  #163  
Old 02-18-2003, 01:52 PM
mheinemann's Avatar
mheinemann mheinemann is offline
 
Join Date: May 2002
Posts: 57
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by J-OST
I installed this but it only shows the same two people every other day. I used the text file provided by vbhacker to install it. Are there known issues with this?
I've been having this problem recently, didn't use to do it though.
Reply With Quote
  #164  
Old 02-19-2003, 09:07 PM
mheinemann's Avatar
mheinemann mheinemann is offline
 
Join Date: May 2002
Posts: 57
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I think I found a fix if you're having this problem

find
PHP Code:
if ($daybits[0]!=$thisdate or ($resetmember==and $bbuserinfo['usergroupid']==6)) { 
below that put
PHP Code:
$seed rand(); 
then find
PHP Code:
$newmember=$DB_site->query_first("SELECT userid,username
                                        FROM user
                                       WHERE userid<>
$daybits[1]
                                        AND (usergroupid=5
                                          OR usergroupid=6
                                          OR usergroupid=7
                                          OR usergroupid=2)
                                       ORDER BY RAND()
                                       LIMIT 1"
); 
replace with
PHP Code:
$newmember=$DB_site->query_first("SELECT userid,username
                                        FROM user
                                       WHERE userid<>
$daybits[1]
                                        AND (usergroupid=5
                                          OR usergroupid=6
                                          OR usergroupid=7
                                          OR usergroupid=2)
                                       ORDER BY RAND(
$seed)
                                       LIMIT 1"
); 
Reply With Quote
  #165  
Old 02-19-2003, 10:49 PM
Mike Gaidin's Avatar
Mike Gaidin Mike Gaidin is offline
 
Join Date: Oct 2001
Location: Michigan
Posts: 247
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'll try that! Thanks!
Reply With Quote
  #166  
Old 02-19-2003, 10:57 PM
mheinemann's Avatar
mheinemann mheinemann is offline
 
Join Date: May 2002
Posts: 57
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Let me know if it works for you.
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 08:58 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.05951 seconds
  • Memory Usage 2,376KB
  • Queries Executed 30 (?)
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
  • (3)bbcode_code
  • (4)bbcode_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (16)post_thanks_box
  • (16)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (16)post_thanks_postbit_info
  • (15)postbit
  • (16)postbit_onlinestatus
  • (16)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
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete