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

Reply
 
Thread Tools
Beta Donation Hack Details »»
Beta Donation Hack
Version: 1.00, by 2root4u 2root4u is offline
Developer Last Online: Aug 2006 Show Printable Version Email this Page

Version: 2.3.x Rating:
Released: 03-10-2003 Last Update: Never Installs: 6
Is in Beta Stage  
No support by the author.

Here is a copy of my donation hack. It does not have a pretty install or admin control panel config.

It features:
- Unlimited/Customizable donation brackets and titles
- Donation titles in all posts below username
- Donation titles next to names in member list
- 'Top Donators' listing in member list

Here you go...try at your own risk

Show Your Support

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

Comments
  #12  
Old 03-12-2003, 11:43 PM
chad777 chad777 is offline
 
Join Date: May 2002
Posts: 173
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I think something like this has already been done...its called the controbutor hack.

When I seen the donation hack I was like great! I kind want something that will allow members to donate and use paypal IPN to send back that they donated and how much they donated then list a top donators list and how much they donated.

Also when donating they would have the option of not being added to the top donator list ..
Reply With Quote
  #13  
Old 03-13-2003, 12:12 AM
2root4u 2root4u is offline
 
Join Date: Feb 2003
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by chad777
I think something like this has already been done...its called the controbutor hack.

When I seen the donation hack I was like great! I kind want something that will allow members to donate and use paypal IPN to send back that they donated and how much they donated then list a top donators list and how much they donated.

Also when donating they would have the option of not being added to the top donator list ..
Wish I had seen that earlier...however in the end, my hack better suits my needs because it allows for different titles based upon the amount donated. Thanks for the info!
Reply With Quote
  #14  
Old 03-15-2003, 05:51 PM
Koopa Koopa is offline
 
Join Date: Nov 2001
Posts: 60
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Nice hack, I will probably use this
Reply With Quote
  #15  
Old 03-21-2003, 04:45 PM
petey20 petey20 is offline
 
Join Date: Mar 2003
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just what I needed.

I only had one issue with your install in admin/functions.php. I"m running v.2.3.0 and where you have to insert the code before

$post[postdate]=vbdate($dateformat,$post[dateline]);
$post[posttime]=vbdate($timeformat,$post[dateline]);

I had to actually place it right before the line

$datecut = time() - $cookietimeout;

to get everything to compile and work correctly. It must have something to do with declaring the globals in the body of function getpostbit. My version didn't like it where you suggest to put it!

Otherwise, thanks a bunch!
Petey
Reply With Quote
  #16  
Old 04-05-2003, 09:55 AM
Lethal Lethal is offline
 
Join Date: Feb 2002
Location: PA/USA
Posts: 164
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I get this error when i try to few the memberlist:

Database error in vBulletin 2.3.0:

Invalid SQL: SELECT *,5+0 as 5
FROM user,userfield
WHERE 1=1 AND
user.userid = userfield.userid
AND usergroupid NOT IN (1,3,4)
ORDER BY username ASC
LIMIT 0,30
mysql error: You have an error in your SQL syntax near '5
FROM user,userfield
WHERE ' at line 1

mysql error number: 1064


And in the postbit no matter what amount of donation I put in, it always shows up as *Diamond Donator*


Something is wrong with this part of the code:

PHP Code:
$users=$DB_site->query("SELECT *,$donationfield+0 as $donationfield
                          FROM user,userfield
                          WHERE 
$condition AND
                                user.userid = userfield.userid
                                "
.iif($memberAllGood" AND usergroupid NOT IN (1,3,4) """)."
                          ORDER BY 
$orderby $direction
                          LIMIT "
.($limitlower-1).",$perpage"); 

I moved stuff around but couldn't get it to work.

I am running 2.3.0

Little help plz
Reply With Quote
  #17  
Old 04-05-2003, 10:59 AM
2root4u 2root4u is offline
 
Join Date: Feb 2003
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Today at 11:55 AM Lethal said this in Post #15
I get this error when i try to few the memberlist:

Database error in vBulletin 2.3.0:

Invalid SQL: SELECT *,5+0 as 5
FROM user,userfield
WHERE 1=1 AND
user.userid = userfield.userid
AND usergroupid NOT IN (1,3,4)
ORDER BY username ASC
LIMIT 0,30
mysql error: You have an error in your SQL syntax near '5
FROM user,userfield
WHERE ' at line 1

mysql error number: 1064


And in the postbit no matter what amount of donation I put in, it always shows up as *Diamond Donator*


Something is wrong with this part of the code:

PHP Code:
$users=$DB_site->query("SELECT *,$donationfield+0 as $donationfield
                          FROM user,userfield
                          WHERE 
$condition AND
                                user.userid = userfield.userid
                                "
.iif($memberAllGood" AND usergroupid NOT IN (1,3,4) """)."
                          ORDER BY 
$orderby $direction
                          LIMIT "
.($limitlower-1).",$perpage"); 

I moved stuff around but couldn't get it to work.

I am running 2.3.0

Little help plz
In $donationfield, specify it as "field5" and not just "5". That should fix it.
Reply With Quote
  #18  
Old 04-05-2003, 11:28 AM
Lethal Lethal is offline
 
Join Date: Feb 2002
Location: PA/USA
Posts: 164
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok that fixed the error, but now it shows up in the postbit but not the memberslist. I double checked the changes in memberslist.php and the templates and everything is ok but it won't show up. The top donators link is there but the label isn't.

??
Reply With Quote
  #19  
Old 04-05-2003, 12:18 PM
2root4u 2root4u is offline
 
Join Date: Feb 2003
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Today at 01:28 PM Lethal said this in Post #17
Ok that fixed the error, but now it shows up in the postbit but not the memberslist. I double checked the changes in memberslist.php and the templates and everything is ok but it won't show up. The top donators link is there but the label isn't.

??
The only thing I can think of is either:
- You don't have '$post[donationtitle]' in your postbit
OR
- You don't have the correct code in functions.php
OR
- You are using a different version of vb
Reply With Quote
  #20  
Old 04-06-2003, 07:32 AM
Lethal Lethal is offline
 
Join Date: Feb 2002
Location: PA/USA
Posts: 164
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

ok well I will go over the changes again 1 by 1 to make sure everything is right. I am using vb 2.3.0
Reply With Quote
  #21  
Old 04-06-2003, 09:40 AM
Lethal Lethal is offline
 
Join Date: Feb 2002
Location: PA/USA
Posts: 164
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I found the problem, in admin/functions.php I had:

PHP Code:
//2root4u Donation Hack
    
global $donationbrackets$donationtitles$donationfield;
    
$donation $post[$donationfield];
    if(
is_numeric($donation) && $donation>$donationbrackets[0]) {
        
$post[donationtitle] = $donationtitles[0];
        
$i 1;
        while(isset(
$donationbrackets[$i]) && ($donation $donationbrackets[$i]))
            
$post[donationtitle] = $donationtitles[$i++];
    }
////End 2root4u Donation Hack 
after:

PHP Code:
$post[postdate]=vbdate($dateformat,$post[dateline]);
$post[posttime]=vbdate($timeformat,$post[dateline]); 
Instead of before it, that fixed it. Nice hack again ty
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 03:51 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.03893 seconds
  • Memory Usage 2,327KB
  • Queries Executed 27 (?)
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
  • (4)bbcode_php
  • (3)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
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)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_postinfo_query
  • fetch_postinfo
  • 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