PDA

View Full Version : Help with Google Checkout API


ChurchMedia
03-10-2008, 08:07 PM
I'm working on a Google Checkout API. Right now I'm stuck with the settings field in the paymentapi table. All I need are two fields -- one for the Vendor ID and one for the Merchant Key. I don't know how to use datastore (would love to learn).

What does this code need to look like? It doesn't work as-is:

a:3:{s:17:"google_vendorid";a:3:{s:4:"type";s:4:"text";s:5:"value";s:12:"";s:8:"validate";s:6:"string";}s:6:"google_merchantkey";a:3:{s:4:"type";s:4:"text";s:5:"value";s:16:"";s:8:"validate";s:6:"string";}}

Thanks!

MoT3rror
03-10-2008, 08:16 PM
Needs to be unserialize (http://www.php.net/manual/en/function.unserialize.php).

ChurchMedia
03-10-2008, 10:06 PM
I didn't actually serialize it, though. I just modified it from the authnet api info. I thought that the subscriptions.php script in the admincp would unserialize it.

This is the way it looks:
77070

Any ideas?

(edit) Yeah, it's here:

if ($_REQUEST['do'] == 'apiedit')
{
$settings = unserialize($api['settings']);
if (is_array($settings))
{

I must not have the code right, but I don't know what to do....

ChurchMedia
03-10-2008, 11:05 PM
I got it:

a:1:{s:17:"google_merchantid";a:3:{s:4:"type";s:4:"text";s:5:"value";s:10:"1234567890";s:8:"validate";s:6:"string";}}

:)

iogames
03-10-2008, 11:45 PM
Would be 3.7.x Integrated Google CheckOut? [Am I missing something?]

ChurchMedia
03-10-2008, 11:50 PM
Would be 3.7.x Integrated Google CheckOut? [Am I missing something?]
Not so far! I wish it was. If the vB team plans to include it, I'd like to know! :)

I've gotten as far as putting together the class_google.php file, but I'm stuck again.

Chewy954
06-08-2008, 08:19 PM
Did you ever get this working?