Back to vBulletin 3.8 Add-ons

Add Google Checkout to Paid Subscriptions
Mod Version: 1.01, by CaseLogic

vB Version: 3.8.x Rating: (9 votes - 4.44 average) Installs: 26
Released: 31 Aug 2010 Last Update: 05 Sep 2010 Downloads: 205
Not Supported DB Changes Uses Plugins Auto-Template Additional Files  

This is my first released mod, so please rate!

This modification will allow you to use Google Checkout as a payment processor for paid subscriptions.

Google Checkout Steps
-Under Settings->Preferences, select the option to automatically authorize and charge
-Under Settings->Integration, uncheck the digitally signed cart box
-For the API Callback URL, enter in the following:
http://path to your forum/payment_gateway.php?method=gcheckout
-Select the Notification Serial # method
-Select API version 2.5 (do NOT check the notification filtering checkbox!)
-Note your Merchant ID and Merchant Key on the right-hand side (will need for below)

vBulletin Steps
-Upload class_gcheckout.php to <forum base>/includes/paymentapi
-Install product
-Under Paid Subscriptions->Payment API Manager->Google Checkout, enter in the merchant ID and key found under your Settings.
-Activate Google Checkout payment API
-Optionally run "Test Communication" under Paid Subscriptions to ensure successful setup and integration

Known Issues
-Incorrect operation on 32bit systems! (found 12/14/2010)

Spoiler (click to open)


I figured out the issue that some (or at least 1) person reported in this thread. There is a problematic intval() call in the form generation function. Merchant ID's are generally very large numbers. intval() is either a 32 bit or a 64 bit function, depending on the host. If it's a 32 bit system, it will max out and cap at the wrong value.

For those running into the "oops!" error, please fix the following line by removing intval:

Code:
$form['action'] = 'https://checkout.google.com/api/checkout/v2/checkoutForm/Merchant/' . intval($settings['gmerchantid']);
to this:

Code:
$form['action'] = 'https://checkout.google.com/api/checkout/v2/checkoutForm/Merchant/' . $settings['gmerchantid'];

Close

-Only works with curl installed
-Chargeback handling not implemented yet

Release notes
1.01
-Replaced mysql_ function in install code with vB SQL wrapper
1.0
- Original version

Download

File Type: %1$s product-gcheckout-1.01.zip (4.1 KB, 204 downloads)


vblts.ru supports vBulletin®, 2022-2024