Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Beta Releases

Reply
 
Thread Tools
Paypal Donations (With Instant Payment Notification) -- RC1 (Public Testing) Details »»
Paypal Donations (With Instant Payment Notification) -- RC1 (Public Testing)
Version: 1.00, by Cloudrunner Cloudrunner is offline
Developer Last Online: Feb 2022 Show Printable Version Email this Page

Version: 2.3.x Rating:
Released: 06-16-2003 Last Update: 06-27-2003 Installs: 51
Is in Beta Stage  
No support by the author.

This hack is obsolete, and is currently being ported to 3.0.7, and will be ported to 3.5 when it is allowed.

Thank you for your understanding.
[b]

Version 0.9.5 is a major fix to a bug that was found by shortywz. Please download the new archive and overwrite your old files to upgrade to 0.9.5 if you are running 0.9.4, if you are running any version lower than 0.9.4 then after overwriting the old files run the installer

Paypal Donations for vBulletin

What it does:
Quite simply this hack provides you a way to receive donations from your website's users and provide them with the recognition deserving of a donating member of you community. It uses Paypal exclusively for the time being because of Paypal's "Instant Payment Notification" system. For more information on Paypal's IPN, please see the supplied manual for IPN located here in the docs directory. The file name is: "IPN.PDF".

The basics are this, your users goto your donations page where you have certain levels of donations available via hyperlinked "buttons". These buttons take your user to paypal's secure payment processing system where they pay you your donation. Once payment has been received, paypal sends your server a notification containing certain information pertaining to that specific transaction. Your server then repeats this information to the verification server (which is hardcoded into the system so that *spoofing* is rendered virtually impossible) which first checks to see if the information was sent by it, then checks the validity of the information. If everything checks out, it then sends your server a response of "VERIFIED". When this hack see that word after running the script it inserts all the information into your database so that you can see what was donated, who donated it, and where.

If the server returns a response of "INVALID" then this script drops the information into a separate table so that you can investigate the transaction further to detect fraud attempts. It also does this on any suspicious entries after a few checks. Once payment is verified and information has been inserted into the tables, the system then adds a few toys and items for the user to be recognized as a donating user. What you do with that recognition is up to you.

Features:
  • You as the admin have the ability to show as little or as much as you want about what happens with your donations.
  • Your users will only see what you want them to see.
  • Can block other admins from seeing the actual payment information (you have to explicitly allow them access to that).
  • Your members who have donated are recognized for doing so in the memberlist and their postbit.
  • You can show your donation goals to the public and on your forumhome.
  • Automatic updates EVERY time a user donates or retracts a donation.
  • Postbit Awards for certain levels of donations that you decide on
  • User has the ability to choose whether they receive the awards recognition
  • Admin can customize the PM sent to donators thanking them for donating.
  • Guest donations are now listed individually, sorted by IP(not displayed) on the Top Ten list, and within the database
**Coming Soon**
  • Add a time-limited feature for the donation buttons
  • Fix guest donations to show each indiviual guest's donations sorted uniquely
  • Integration with Lesane's Store Hack
  • The ability to verify Paypal's Secure Server ID and transfer the payment information via SSL if you have that enabled
Stuff you have to do:
Files to upload: 9
Files to modify: 7
Templates to modify: 4
Queries to run: (The install script does this for you, uninstallation is also provided as well)
Ease of install: Simple, but abit intensive with some file edits
Time of install: ~10 minutes

***REMEMBER! Add your email address that Paypal has on file in the ppfunc.php file. This step is not an option, your payments, although they may be valid, will all be considered invalid if you do not do this! Sign up for Paypal's Premiere Account (Business), and setup IPN.

Paypal Registration:
You will need to register with Paypal for a premiere account if you have not already, if you have, but your account is probably a personal account, you will need to upgrade the account to a premiere account. Assuming that you have a premiere account and have been verified, you then go into your profile at https://www.paypal.com and the select Instant Payment Notification. There will be a checkbox that you must check, and an inputbox where you will need to place your script file. Simply place your entire URL to the paypal.php file there.

On most systems it will be either:

http://www.yourdomain.com/paypal.php

or

http://www.yourdomain.com/forum/paypal.php

That's all there is to setting up Paypal to work with your site!

Install:
Upload the following files to your $ROOT/forum directory:

paypal.php
ppverify.php
ppfunc.php

Upload the following files to your $ROOT/forum/admin directory:

paypal_admin.php
paypal_donations_install.php

Upload the following files to your $ROOT/forum/images directory:

donate.gif
donate2.gif
donate3.gif
donate4.gif

Run the provided install file, after installation, DELETE THE FILE!

This will usually be:

http://www.yourdomain.com/forum/admi...ns_install.php

or

http://www.yourdomain.com/admin/payp...ns_install.php

Upgrading:
Upload the following files to your $ROOT/forum directory overwriting the old files:

paypal.php
ppverify.php
ppfunc.php

Upload the following files to your $ROOT/forum/admin directory:

paypal_admin.php
paypal_donations_install.php

Upload the following files to your $ROOT/forum/images directory:

donate.gif
donate2.gif
donate3.gif
donate4.gif

Run the provided install file and follow the upgrade instructions, after upgrading, DELETE THE FILE!

This will usually be:

http://www.yourdomain.com/forum/admi...ns_install.php

or

http://www.yourdomain.com/admin/payp...ns_install.php

After Install:
You will need to add a link somewhere in your navigation system for vBulletin pointing your users to the donations page.

------------------------------------------------------------------------
I sincerely hope that you enjoy this hack.

This thread is specifically for the use of bugs reporting and feature suggestions.

You are allowed to hack the crap outta this here script for your own personal use, BUT, if you do, I will not be able to provide you with support for the system if the base code has been changed! Also, if we find another hack that interferes with this one, I will do my best to provide a work around for it, but I will not garuantee that to occur!

For those of you who have been alpha testing this for me, THANK YOU! To upgrade from Alpha to Beta, you will have to do a complete uninstall (including file modifications) and reinstall. This is due to the extensive redo of code in vb resident pages. I hope you can understand.

Thank you!

)O( Cloudrunner )O(

P.s. --> I you want to be notified whenever I updated the Paypal Donations System, I suggest that you push that little button up top and down below that says install, It's especially useful to you to do so, cus when a New Version comes out, I can simply update and anyone who has it installed will be notified.....Just a suggestion...

A special thank goes out to ap0c for keeping me on my toes during Alpha testing...dude can find some bugs, lemme tell ya! And thanks for the suggestions as well bro! I added all of em.

Attached is the full release which includes screenshots and the manuals from Paypal for IPN and Donations for those of you who really want to play with the code for reference. Warning, the file is large!

If you want a smaller file, then look here. The archive in that post is the smaller of the two at ~30K compared to ~1M. It does NOT contain the manuals OR the screens (as requested by gmarik).

Enjoy

(with the addition of the manuals and screens, the archive is too big to attach. If you want these, pm me and I'll send it them too you, or simply download the screens archive a few posts down, and then download the manuals from Paypal.)

Supporters / CoAuthors

Show Your Support

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

Comments
  #52  
Old 06-24-2003, 11:47 AM
Rebel38 Rebel38 is offline
 
Join Date: Feb 2003
Posts: 20
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Yesterday at 05:58 AM Cloudrunner said this in Post #44
Actually, the item_number column was removed for the guest posters portion of the hack...unfortunately, this is my fault, I forgot to remove that in the paypal_admin.php.

I will fix it and get the fixed archive up again.

bug found

mist, okay, I'm not quite understanding again...you want the donation button to be displayed for xxx amount of (days, weeks, months, years, etc). and then upon expiration anyone who donated using that button get their awards and such removed right? What about the topten listing? do we want them removed from there as well?

I fix my post upstairs too...sorry, I thought it was funny :P

Okay to fix the donate_buttons query before I get the new archive up here:

in paypal_admin.php find:
PHP Code:
  $DB_site->query("INSERT INTO paypal_donatebuttons (id,
                                                     business,
                                                     item_name, 
Replace that entire query with this:
PHP Code:
  $DB_site->query("INSERT INTO paypal_donatebuttons (id,
                                                     business,
                                                     item_name,
                                                     image_url,
                                                     no_shipping,
                                                     return,
                                                     rm,
                                                     cancel_return,
                                                     no_note,
                                                     cn,
                                                     cs,
                                                     invoice,
                                                     tax,
                                                     currency_code,
                                                     amount,
                                                     submit_button) VALUES (NULL, '"
                                                     
.addslashes($options['business_email'])
                                                     .
"', '"
                                                     
.addslashes($_POST['item_name'])
                                                     .
"', '"
                                                     
.addslashes($_POST['image_url'])
                                                     .
"', '', '"
                                                     
.addslashes($return)
                                                     .
"', '"
                                                     
.addslashes($_POST['rm'])
                                                     .
"', '"
                                                     
.addslashes($cancel_return)
                                                     .
"', '', '"
                                                     
.addslashes($_POST['cn'])
                                                     .
"', '"
                                                     
.addslashes($_POST['cs'])
                                                     .
"', '"
                                                     
.addslashes($_POST['invoice'])
                                                     .
"', '"
                                                     
.addslashes($_POST['tax'])
                                                     .
"', '"
                                                     
.addslashes($_POST['currency_code'])
                                                     .
"', '"
                                                     
.addslashes($_POST['amount'])
                                                     .
"', '"
                                                     
.addslashes($_POST['submit_button'])
                                                     .
"')"); 
then find this:
PHP Code:
$DB_site->query("UPDATE paypal_donatebuttons SET business = '" 
and replace that entire query with this:
PHP Code:
  $DB_site->query("UPDATE paypal_donatebuttons SET business = '"
                 
.addslashes($options['business_email'])
                 .
"', item_name = '"
                 
.addslashes($_POST['item_name'])
                 .
"', image_url = '"
                 
.addslashes($_POST['image_url'])
                 .
"', return = '"
                 
.addslashes($return)
                 .
"', rm = '"
                 
.addslashes($_POST['rm'])
                 .
"', cancel_return = '"
                 
.addslashes($cancel_return)
                 .
"', cn = '"
                 
.addslashes($_POST['cn'])
                 .
"', cs = '"
                 
.addslashes($_POST['cs'])
                 .
"', invoice = '"
                 
.addslashes($_POST['invoice'])
                 .
"', tax = '"
                 
.addslashes($_POST['tax'])
                 .
"', currency_code = '"
                 
.addslashes($_POST['currency_code'])
                 .
"', amount = '"
                 
.addslashes($_POST['amount'])
                 .
"', submit_button = '"
                 
.addslashes($_POST['submit_button'])
                 .
"' WHERE id = '"
                 
.$_POST['id']
                 .
"'"); 
The queries both end the line before
PHP Code:
echo "All good!"
The file is fixed, but won't be up until next update, so in the interrim use this to fix the problem.
Thanks Cloudrunner, it's working fine now, great hack to mate alot of people have been waiting for this,

Clicks install

Thanks again
Rebel
Reply With Quote
  #53  
Old 06-24-2003, 01:39 PM
Crazy Pete Crazy Pete is offline
 
Join Date: Nov 2002
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Today at 01:12 AM Cloudrunner said this in Post #50
Crazy Pete--

Both database errors were addressed already

https://vborg.vbsupport.ru/showthrea...663#post411663

And a bug found as well after that one was addressed:

https://vborg.vbsupport.ru/showthrea...680#post411680
Ahh, thanks for that. I s'pose it's always best to actually look and search in the thread first eh?
Reply With Quote
  #54  
Old 06-24-2003, 06:38 PM
Cloudrunner's Avatar
Cloudrunner Cloudrunner is offline
 
Join Date: May 2003
Location: Butte, MT
Posts: 635
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Crazy Pete--

usually

smile! Life is grand!

Rebel38--

Thank you for the kind words! But don't forget the second fix just below the database repair, or you won't be notified of any of your payments
Reply With Quote
  #55  
Old 06-25-2003, 01:31 AM
Cloudrunner's Avatar
Cloudrunner Cloudrunner is offline
 
Join Date: May 2003
Location: Butte, MT
Posts: 635
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

ALERT!!!

Right now as the code sits, There is a major bug in the code where nothing updates properly, you'll still recieve the donations and everything, but it's not displaying!

Please disable the link to your hack until I can get this fixed. I'm working on the problem with Shorty, and should get an updated release up soon!

Thank you for your patience and understanding on this!

)O( Cloudrunner )O(
Reply With Quote
  #56  
Old 06-25-2003, 03:31 AM
Cloudrunner's Avatar
Cloudrunner Cloudrunner is offline
 
Join Date: May 2003
Location: Butte, MT
Posts: 635
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

All fixed!

Please download the new version. If you are running version 0.9.4 then all you have to do is upload the new files overwriting the old ones.

If you are running a version prior to 0.9.4 then you'll need to run the installer and upgrade from your version.

This update fixes a bug found by shortywz where a new donator does not show up on the main donators page. This has been fixed. I also cleaned up some more code, and a slight adjustment to the adminCP.
Reply With Quote
  #57  
Old 06-25-2003, 03:44 AM
Cloudrunner's Avatar
Cloudrunner Cloudrunner is offline
 
Join Date: May 2003
Location: Butte, MT
Posts: 635
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

yak!

Sorry, missed a line...archive is updated again for 0.9.5...

if you downloaded paypal_donations(0.9.5).zip, then please download the new one: paypal_donations(0.9.5.beta--noscreens).zip

Thanks! (sorry about that )

)O( Cloudrunner )O(
Reply With Quote
  #58  
Old 06-25-2003, 03:53 AM
Cloudrunner's Avatar
Cloudrunner Cloudrunner is offline
 
Join Date: May 2003
Location: Butte, MT
Posts: 635
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Before I forget--

Shorty! Bro, yer the man! Thank you for giving me a hand on this one, I appreciated it greatly!

You all should thank shorty for finding the bug and helping me to fix it up, cus without him it woulda slipped through the cracks!

Thanks!

)O( Cloudrunner )O(
Reply With Quote
  #59  
Old 06-25-2003, 01:26 PM
Crazy Pete Crazy Pete is offline
 
Join Date: Nov 2002
Posts: 155
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks very much you guys! It's nice to see a really well thought-out hack with such great support for it.
Reply With Quote
  #60  
Old 06-28-2003, 01:31 AM
Cloudrunner's Avatar
Cloudrunner Cloudrunner is offline
 
Join Date: May 2003
Location: Butte, MT
Posts: 635
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well, it looks as though most of the major bugs have been worked out so far, Please let me know how it is running for you all who have installed this hack.

If there is still no bugs found in the next week or so, I'll be moving this to a full release (this is due to the fact that most of the coding adjustments are mostly features and addons to this hack that I will be doing when I am able to, there are a few updates that I will be doing to this, but all in due time of course).

Please let me know of any problems, and of course any more suggestions to the hack so that I may add them to the ToDo List.

Thanks for the help and support guys!

)O( Cloudrunner )O(
Reply With Quote
  #61  
Old 07-02-2003, 12:57 PM
Shepski Shepski is offline
 
Join Date: Jul 2002
Posts: 72
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hiya, this is a great hack but i think i may have done something wrong. I have run thru the install and now sent some money to my account using visa but when I click continue on paypal to send me back to my site I get the following:
Code:
Database error in vBulletin 2.2.6:

Invalid SQL: INSERT INTO paypal_funds (id, date, donated) VALUES ('0E567297NG154303X', NOW(), '4.63')
mysql error: 

mysql error number: 

Date: Wednesday 02nd of July 2003 03:00:26 PM
Script: http://forums.dvd-swaps.co.uk/paypal.php?action=success
Referer:
it does seem to be updating my user profile to say how much i have donated so not sure what this mysql error is relating to.

Any ideas?
Reply With Quote
Reply

Thread Tools

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 01:17 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04954 seconds
  • Memory Usage 2,378KB
  • Queries Executed 26 (?)
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
  • (1)bbcode_code
  • (5)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
  • (1)pagenav_pagelinkrel
  • (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_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