Zen Cart Logo
Forums / Addon Payment Modules / Google Checkout module for ZC 1.3.x (beta)

Google Checkout module for ZC 1.3.x (beta)

Locked

Views: 1,099,664

Results 961 to 980 of 3,921
This thread is locked. New replies are disabled.
1 Apr 2007, 10:50 PM
#961
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Google Checkout module for ZC 1.3.x (beta)

knuckle-101:

Ayone got any idea whats causing this error?

I have tried everyhting I can think of

Oops!
Sprite Mobile Ltd. has sent Google a shopping cart with errors in it. We'll contact them to ask that they fix this problem. As this could be a temporary issue, you can go back in your browser to try checking out again.

Log in to your GoogleCheckout seller account>Integration>Settings and there you will have more details with an specific error and possible causes.

1 Apr 2007, 10:56 PM
#962
blessisaacola avatar

blessisaacola

Totally Zenned

Join Date:
Feb 2004
Location:
Georgia, USA
Posts:
1,875
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

tj1:

I believe the template files are based on 1.3.6, not 1.3.7.
In 1.3.7, the files contain code for PayPal Express and as someone else mentioned, if you also want to use PayPal Express, you'd need to merge both files otherwise one or the other payment modules will be broken.

ropu, it would be great if you could base the template files and instructions on 1.3.7 this way no code will be broken or one won't have to merge code from two files.

Here are the version ids of the template files:

Current: tpl_checkout_payment_default.php 5414 2006-12-27 07:51:03Z drbyte
Used on GC: tpl_checkout_payment_default.php 4332 2006-09-01 04:33:16Z ajeh

Current: tpl_login_default.php 5419 2006-12-28 05:56:39Z drbyte
Used on GC: tpl_login_default.php 2834 2006-01-11 22:16:37Z birdbrain

Current: tpl_shopping_cart_default.php 5414 2006-12-27 07:51:03Z drbyte
Used on GC: tpl_shopping_cart_default.php 4140 2006-08-15 03:37:53Z drbyte

My bad, I meant that ropu's new release did not have any changes to the template. There has been no change to the actual templates files since 1.0.5. My assumption is you've had this working at one point or the other which meant you wouldn't have applied the code from GoogleCheckout to the three template files affected as well as applied the code changes to admin/orders.php.

If you didn't have a working template with these changes then you need to obviously apply the code changes to your templates.

I am using ZV 1.3.7 and Googlecheckout and PayPal Express are cohabitating just fine once the code is applied to the templates.

1 Apr 2007, 11:01 PM
#963
blessisaacola avatar

blessisaacola

Totally Zenned

Join Date:
Feb 2004
Location:
Georgia, USA
Posts:
1,875
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

knuckle-101:

Ayone got any idea whats causing this error?

I have tried everyhting I can think of

Oops!
Sprite Mobile Ltd. has sent Google a shopping cart with errors in it. We'll contact them to ask that they fix this problem. As this could be a temporary issue, you can go back in your browser to try checking out again.

Just for testing purpose,

  1. make sure that all your shipping options in Admin-Module-Shipping have zone set to none (this should give you all green status).

  2. Make sure if you have tax zone set up that all your shipping options in Admin-Module-Shipping are all using the same tax zone.

Test GoogleCheckout again and report back.

PS. Which version of googlecheckout are you using?

2 Apr 2007, 12:17 AM
#964
blessisaacola avatar

blessisaacola

Totally Zenned

Join Date:
Feb 2004
Location:
Georgia, USA
Posts:
1,875
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

Chain_man, here is my code based on version 1.3. Please note that I have removed fedex1 as that's a duplicate as well as all shipping options that we don't actually offer on our site.

$this->mc_shipping_methods = array(
                        'usps' => array(
                                    'domestic_types' =>
                                      array(
                                          'Express' => 'Express Mail',
                                          'First Class' => 'First-Class Mail',
                                          'Priority' => 'Priority Mail'
                                           ),

                                    'international_types' =>
                                      array(
                                          'Express' => 'Global Express Mail (EMS)',
                                          'Priority Var' => 'Global Priority Mail - Variable Weight Envelope (single)'
                                           ),
                                        ),
                        'ups' => array(
                                    'domestic_types' =>
                                      array(
                                          '1DA' => 'Next Day Air',
                                          '1DP' => 'Next Day Air Saver',
                                          '2DA' => '2nd Day Air',
                                          '3DS' => '3 Day Select',
                                          'GND' => 'Ground',
                                          'STD' => 'Canada Standard',
                                          'XPR' => 'Worldwide Express'
                                           ),

                                    'international_types' =>
                                      array(

                                           ),
                                        ),
                        'zones' => array(
                                    'domestic_types' =>
                                      array(
                                          'zones' => 'Zones Rates'
                                           ),

                                    'international_types' =>
                                      array(
                                          'zones' => 'Zones Rates intl'
                                           ),
                                        ),
                        'fedexexpress' => array(
                                    'domestic_types' =>
                                      array(
                                          '03' => 'FedEx 2Day',
                                          '05' => 'FedEx Standard Overnight',
                                          '06' => 'FedEx First Overnight',
                                          '20' => 'FedEx Express Saver'
                                           ),

                                    'international_types' =>
                                      array(
                                          '03' => 'FedEx International Economy',
                                          '06' => 'FedEx International First'
                                           ),
                                        ),
                        'fedexground' => array(
                                    'domestic_types' =>
                                      array(
                                          '90' => 'FedEx Home Delivery',
                                          '92' => 'FedEx Ground Service'
                                           ),

                                    'international_types' =>
                                      array(
                                          '90' => 'International Home Delivery',
                                          '92' => 'International Ground Service'
                                           ),
                                        ),
                        'freeoptions' => array(
                                    'domestic_types' =>
                                      array(
                                          'freeoptions' => 'Free Options'
                                           ),

                                    'international_types' =>
                                      array(
                                          'freeoptions' => 'Free Options intl'
                                           ),
                                        ),
                        'freeshipper' => array(
                                    'domestic_types' =>
                                      array(
                                          'freeshipper' => 'Free Shipper'
                                           ),

                                    'international_types' =>
                                      array(
                                          'freeshipper' => 'Free Shipper intl'
                                           ),
                                        ),
                        'perweightunit' => array(
                                    'domestic_types' =>
                                      array(
                                          'perweightunit' => 'Perweight Unit'
                                           ),

                                    'international_types' =>
                                      array(
                                          'perweightunit' => 'Perweight Unit intl'
                                           ),
                                        ),
                        'storepickup' => array(
                                    'domestic_types' =>
                                      array(
                                          'storepickup' => 'Store Pickup'
                                           ),

                                    'international_types' =>
                                      array(
                                          'storepickup' => 'Store Pickup intl'
                                           ),
                                        ),
                        'flat' => array(
                                    'domestic_types' =>
                                      array(
                                          'flat' => 'Flat Rate Per Order'
                                           ),

                                    'international_types' =>
                                      array(
                                          'flat' => 'Flat Rate Per Order intl'
                                           ),
                                        ),
                        'item' => array(
                                    'domestic_types' =>
                                      array(
                                          'item' => 'Flat Rate Per Item'
                                           ),

                                    'international_types' =>
                                      array(
                                          'item' => 'Flat Rate Per Item intl'
                                           ),
                                        ),
                        'table' => array(
                                    'domestic_types' =>
                                      array(
                                          'table' => 'Vary by Weight/Price'
                                           ),

                                    'international_types' =>
                                      array(
                                          'table' => 'Vary by Weight/Price intl'
                                           ),
                                        ),
                                  );

$this->mc_shipping_methods_names = array(
                                         'usps' => 'USPS',
                                         'ups' => 'UPS',
                                         'zones' => 'Zones',
                                         'fedexexpress' => 'Fedex Express',
                                         'fedexground' => 'Fedex Ground',
                                         'freeoptions' => 'Free Options',
                                         'freeshipper' => 'Free Shipper',
                                         'perweightunit' => 'Perweight Unit',
                                         'storepickup' => 'Store Pickup',
                                         'flat' => 'Flat Rate',
                                         'item' => 'Item',
                                         'table' => 'Table',
                                        );
2 Apr 2007, 12:33 AM
#965
chain_man avatar

chain_man

Zen Follower

Join Date:
Dec 2005
Location:
Box Elder, SD
Posts:
375
Plugin Contributions:
0

Re: Google Checkout module for ZC 1.3.x (beta)

BlessIsaacola:

The only shipping options available are the ones that we've actually configured on the admin side module-shipping.

ropu, helped me out with out to set this up to work correctly (I have a feeling ropu will release a tool in the future to help others).

There was actually a duplicate fedex1 in the originally file downloaded by ropu and that was completely deleted from my file after getting help from ropu.

considering that merchant shipping calculation is pretty touched it's important to have things set right.

Okay, I just realized the above code I posted is from my 1.2RC4REV1. I will post updated code based on 1.3

Thanks! That's just what I needed! I cleared all the details from all the array declarations that I don't use, in the fashion you showed above, and I got decent test results!!

2 Apr 2007, 2:32 AM
#966
2004g35 avatar

2004g35

Zen Follower

Join Date:
Jan 2005
Location:
Winter Haven, FL
Posts:
156
Plugin Contributions:
0

Re: Google Checkout module for ZC 1.3.x (beta)

I set up a Google Checkout account - but after reading 97 pages of posts (must be near some type of record for Zen Forum) , it looks like setting this up might be more than the average person can tackle. Is there anyone who is offering to set Zen 1.3.7 stores up with Google Checkout - for a nominal fee of course.? Thanks

2 Apr 2007, 4:06 AM
#967
blessisaacola avatar

blessisaacola

Totally Zenned

Join Date:
Feb 2004
Location:
Georgia, USA
Posts:
1,875
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

2004g35:

I set up a Google Checkout account - but after reading 97 pages of posts (must be near some type of record for Zen Forum) , it looks like setting this up might be more than the average person can tackle. Is there anyone who is offering to set Zen 1.3.7 stores up with Google Checkout - for a nominal fee of course.? Thanks

What's wrong with your current installation of Google Checkout? Do you have a url we can take look at for how your Google Checkout is working?

2 Apr 2007, 4:37 AM
#968
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Re: Google Checkout module for ZC 1.3.x (beta)

2004g35:

I set up a Google Checkout account - but after reading 97 pages of posts (must be near some type of record for Zen Forum) , it looks like setting this up might be more than the average person can tackle. Is there anyone who is offering to set Zen 1.3.7 stores up with Google Checkout - for a nominal fee of course.? Thanks

Don't get discouraged, it's actually very easy to install. My technical knowledge is very limited and I was able to install it correctly on the first try in about 10 minutes and without getting any errors.

I thought the same thing when I saw all the pages, but I gave it a shot and I'm glad I did, it's very easy to install.

2 Apr 2007, 5:14 AM
#969
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Re: Google Checkout module for ZC 1.3.x (beta)

After successfully testing on a test store, I tried to use it on a live store and I got this error when displaying the contents of the cart:


Warning: main(admin/includes/configure.php) [function.main]: failed to open stream: No such file or directory in /public_html/googlecheckout/gcheckout.php on line 33

Fatal error: main() [function.require]: Failed opening required 'admin/includes/configure.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /public_html/googlecheckout/gcheckout.php on line 33


I think the cause of this error is that I, as any ZC user should as recommended for security, have renamed the admin directory.

Line 33 on googlecheckout/gcheckout.php reads:
require_once('admin/includes/configure.php');

I think the instructions should mention one should change this line if the one has renamed the admin directory.

2 Apr 2007, 5:34 AM
#970
blessisaacola avatar

blessisaacola

Totally Zenned

Join Date:
Feb 2004
Location:
Georgia, USA
Posts:
1,875
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

tj1:

After successfully testing on a test store, I tried to use it on a live store and I got this error when displaying the contents of the cart:


Warning: main(admin/includes/configure.php) [function.main]: failed to open stream: No such file or directory in /public_html/googlecheckout/gcheckout.php on line 33

Fatal error: main() [function.require]: Failed opening required 'admin/includes/configure.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /public_html/googlecheckout/gcheckout.php on line 33


I think the cause of this error is that I, as any ZC user should as recommended for security, have renamed the admin directory.

Line 33 on googlecheckout/gcheckout.php reads:
require_once('admin/includes/configure.php');

I think the instructions should mention one should change this line if the one has renamed the admin directory.

Better yet, the code should be smart enough to read the current admin directory instead of being hard coded. Thanks for sharing your solution with the community.

2 Apr 2007, 9:14 PM
#971
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Re: Google Checkout module for ZC 1.3.x (beta)

BlessIsaacola, how do you get the $10 bonus showing up on your GoogleCheckout button? Mine shows the regular button.

3 Apr 2007, 1:07 AM
#972
blessisaacola avatar

blessisaacola

Totally Zenned

Join Date:
Feb 2004
Location:
Georgia, USA
Posts:
1,875
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

tj1:

BlessIsaacola, how do you get the $10 bonus showing up on your GoogleCheckout button? Mine shows the regular button.

Are you using your production merchant account or sandbox? You need your production merchant account for the promo button to work.

3 Apr 2007, 2:32 AM
#973
chain_man avatar

chain_man

Zen Follower

Join Date:
Dec 2005
Location:
Box Elder, SD
Posts:
375
Plugin Contributions:
0

Re: Google Checkout module for ZC 1.3.x (beta)

tj1:

BlessIsaacola, how do you get the $10 bonus showing up on your GoogleCheckout button? Mine shows the regular button.

It appears that the button style is determined by your merchant account. I have the exact same URL for my button as does BlessIsaacola (except for the merchant number) and my button does not display the $10 off style button.

BlessIsaacola, did you have to sign up with Google for any special promotions?

Thanks,

3 Apr 2007, 2:37 AM
#974
chain_man avatar

chain_man

Zen Follower

Join Date:
Dec 2005
Location:
Box Elder, SD
Posts:
375
Plugin Contributions:
0

Re: Google Checkout module for ZC 1.3.x (beta)

ropu -

I hope you are enjoying a well-deserved holiday there in Argentina!!

I really appreciate all the hard work you have put into this module! And I'm overjoyed to say I have merchant calculated shipping and taxes working just fine on my site now in cohabitation with PayPal Express checkout!!

Well done!!

3 Apr 2007, 3:00 AM
#975
woodymon avatar

woodymon

Totally Zenned

Join Date:
Sep 2004
Posts:
2,309
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

Hi Ropu-

When you have a chance after your vacation could you please check out my previous post:
http://www.zen-cart.com/forum/showpost.php?p=350563&postcount=937

I'm still hoping for some ideas/methods on how to allow Google Checkout be used for physical products but disallow customers to use GC for softgoods. I appreciate your getting back to me on this. If you have absolutely no ideas on how to implement such behavior please let me know and I will shut up :wink2:

Woody

3 Apr 2007, 3:05 AM
#976
chain_man avatar

chain_man

Zen Follower

Join Date:
Dec 2005
Location:
Box Elder, SD
Posts:
375
Plugin Contributions:
0

Re: Google Checkout module for ZC 1.3.x (beta)

Woodymon:

Hi Ropu-

When you have a chance after your vacation could you please check out my previous post:
http://www.zen-cart.com/forum/showpost.php?p=350563&postcount=937

I'm still hoping for some ideas/methods on how to allow Google Checkout be used for physical products but disallow customers to use GC for softgoods. I appreciate your getting back to me on this. If you have absolutely no ideas on how to implement such behavior please let me know and I will shut up :wink2:

Woody

Woody -

Have you looked at ropu's last release? There's an admin option to disable checkout for Virtual Goods. Is that what you were looking for?

3 Apr 2007, 4:32 AM
#977
woodymon avatar

woodymon

Totally Zenned

Join Date:
Sep 2004
Posts:
2,309
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

chain_man:

Woody -

Have you looked at ropu's last release? There's an admin option to disable checkout for Virtual Goods. Is that what you were looking for?

Thanks Chainman. I missed seeing that in ropu's 1.3RC1 announce last Friday.
http://www.zen-cart.com/forum/showpost.php?p=351083&postcount=941
Now I see the last item listed:

Add a configuration to disable Google Checkout Button when are virtual good in the cart
Thanks Ropu!

However when I scanned thru the "Progam Policies and Guidles" at http://checkout.google.com/seller/policies.html#4

  1. g. Google Checkout may be unsupported no more than 5% of the time, in which case you are required to display the 'not available' button as described in 4f. At least 95% of the time, Google Checkout must be offered as a checkout option, with the standard Google Checkout button prominently displayed.

I'm uncertain how to interpret "Google Checkout must be available as a checkout option at least 95% of the time". This is vague and ambiguous. In this regard how is "time" defined.

I can say about 75% of out items are physical goods and the other 25% are downloads. So would this disqualify us?

However, I can say in regards to total historical shop "sales" the downloads amount to less than 5% in both dollar purchases and unit volume. So would this qualify?

If not I guess this rules us out! Argh.

An unrelated question. If the GC for ZC mod is installed, where does the "checkout" link in Zen Cart main menu (in the header) point to?

Woody

3 Apr 2007, 8:20 AM
#978
woodymon avatar

woodymon

Totally Zenned

Join Date:
Sep 2004
Posts:
2,309
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

Thank you Ropu for updated 1.30RC1rev1 mod and the included helpful readme and install documentation.

Good to see the payment module install only requires the merging (replacing) of five clearly defined code snippets into four Zen Cart files (/admin/orders.php and three template files). Makes for a straight forward installation.

Some questions/comments regards to a few entries in each doc.

I. README:

A. I'm a little confused by the organization of the section below. Does this info apply ONLY to those whom are running PHP as CGI? Or does the "spoofed messages" issue apply to everyone?

.htaccess Basic Authentication Mode with PHP over CGI?
If your site is installed on a PHP CGI you must disable Basic Authentication over PHP.
To avoid spoofed messages reaching responsehandler.php, set the .htaccess file with the script linked (http://your-site/admin/includes/htaccess.php%29.
Set permission 777 for http://your-site/googlecheckout/ before running the script. Remember to turn back permissions after creating the files.

B. The following item is listed in the "Common Mistakes" section but I don't see this step listed previously in the readme step-by-step process. Is this set in Google Checkout account on the Google server or in the Zen Cart payment module admin?

Set your Google callback url to https://<url-site-url>/googlecheckout/responsehandler.php
In Sandbox, SSL is not required. In Live mode, SSL is required.

C. The following entry in the readme toubleshooting section references "see above fix" Not sure what that "above fix" is?

Problem: Fatal error: Call to undefined function: getallheaders() error.
Solution: You webhosting company does not have the function getallheaders() enable on your webserver. See above for fix.

II. INSTALLATION

A. Regards to "Option B" for merging code.

I suspect the path below:

  1. YOUR_ZENCART_FOLDER/admin/orders.php/includes/templates/YOUR_TEMPLATE/templates/tpl_checkout_payment_default.php

should be:

  1. YOUR_ZENCART_FOLDER/includes/templates/YOUR_TEMPLATE/templates/tpl_checkout_payment_default.php

Thanks!
Woody

3 Apr 2007, 10:06 AM
#979
woodymon avatar

woodymon

Totally Zenned

Join Date:
Sep 2004
Posts:
2,309
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

I'm in the middle of installing the latest version, and came up to a code merge roadblock...

In my stock Zen Cart 1.37 file:

 * @version $Id: tpl_checkout_payment_default.php 5414 2006-12-27 07:51:03Z drbyte $

I find this file does not contain the following specific code fragment which Option B in the install doc says to replace (starting at line 127):

<?php
    if (sizeof($selection) > 1) {
  ?>

I have for line 117-121

<?php
  $selection = $payment_modules->selection();
  if (sizeof($selection) > 1) {
?>

But this is not the same as in the install doc.
So if I edit as suggested then I am suppose to delete the following line?

$selection = $payment_modules->selection();

So I'm not sure what to replace???

Further below I found on line 136-139:

<?php
    if (sizeof($selection) > 1) {
        if (empty($selection[$i]['noradio'])) {
 ?>

But I don't think it was this block that was referenced.

I do not know which to replace?

A related recommend. In the current OPTION B install instructions, it would be very helpful if some "reference" code was provided, both above and below the various code snippets that need replaced. This would be especially helpful in locating/replacing small code fragments (as in the above example). Thanks.

Woody

3 Apr 2007, 10:18 AM
#980
blessisaacola avatar

blessisaacola

Totally Zenned

Join Date:
Feb 2004
Location:
Georgia, USA
Posts:
1,875
Plugin Contributions:
1

Re: Google Checkout module for ZC 1.3.x (beta)

Woodymon:

I'm in the middle of installing the latest version, and came up to a code merge roadblock...

In my stock Zen Cart 1.37 file:

  • @version $Id: tpl_checkout_payment_default.php 5414 2006-12-27 07:51:03Z drbyte $
> I find this file does not contain the following specific code fragment which Option B in the install doc says to replace (starting at line 127):
> ```
<?php
    if (sizeof($selection) > 1) {
  ?>

I have for line 117-121

<?php $selection = $payment_modules->selection(); if (sizeof($selection) > 1) { ?>
> But this is not the same as in the install doc.
> So if I edit as suggested then I am suppose to delete the following line?
>   ```
$selection = $payment_modules->selection();

So I'm not sure what to replace???

Further below I found on line 136-139:

<?php if (sizeof($selection) > 1) { if (empty($selection[$i]['noradio'])) { ?>
> But I don't think it was this block that was referenced.
> 
> I do not know which to replace?
> 
> A related recommend. In the current OPTION B install instructions, it would be very helpful if some "reference" code was provided, both above and below the various code snippets that need replaced. This would be especially helpful in locating/replacing small code fragments (as in the above example). Thanks.
> 
> Woody

Woody,

This has been discussed in previous posts. The reference in the install instruction is actually wrong. Ropu was using a different template than 1.3.7 when that instruction was written and obviously it hasn't been changed. If you want me to email you my tpl_checkout_payment_default.php for comparison I can do that.

Also, know of the template files are different since version 1.0.5 so if you have a working template with the code changes that is already based on ZC V1.3.7 you're good.