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,791

Results 1,061 to 1,080 of 3,921
This thread is locked. New replies are disabled.
7 Apr 2007, 5:46 AM
#1061
woodymon avatar

woodymon

Totally Zenned

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

Google Checkout module for ZC 1.3.x (beta)

tj1:

The problem is, I have the Low Order Fee implemented in ZenCart and GC is not taking this into account.

I was not even aware Low Order Fees were allowed by credit card companies (or minimum orders). I had always understood that was violation of the TOS. But I may be wrong.

I think I observed something on Google Checkout Merchants forum stating Low Order Fees were not supported. But I could be wrong.

But I did see on the wishlist URL I posted several days ago a statement that Minimum Order fees are not supported by Google Checkout.

You might want to post your feature request there.
http://groups.google.com/group/google-checkout-developers-forum/web/new-feature-suggestions-for-google-checkout

Woody

7 Apr 2007, 6:11 AM
#1062
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)

spf:

This is when I checkout using GCO from my website, my merchant calculated shipping didn't show up, nor does the coupon work. I am trying to figure out what have been broken.

BTW, my GCo was working fine. Until today I decided to try to install authorize.net module on my website, which went ok, then all of sudden the GCO starts having all kinds of issues.

Basic questions:

Are these errors occurring when your shop is setup with a Google Checkout sandbox account or a live/production account?

From your previous post regarding .htaccess issue it appears you are running PHP as CGI. Are you certain that is true? Your host can tell you.

If you are certain running PHP as CGI you can visit Ropu's site and use his generator to create an .htaccess file.
http://demo.globant.com/~brovagnati/tools/

When did your error occur? Immediately after you click the the GCO checkout image on your shop?

What does the error log report? response_error.php

What was the effect when you uninstalled authorize.net payment module? Any difference?

Woody

7 Apr 2007, 7:54 PM
#1063
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)

Woodymon:

I was not even aware Low Order Fees were allowed by credit card companies (or minimum orders). I had always understood that was violation of the TOS. But I may be wrong.

I think I observed something on Google Checkout Merchants forum stating Low Order Fees were not supported. But I could be wrong.

But I did see on the wishlist URL I posted several days ago a statement that Minimum Order fees are not supported by Google Checkout.

You might want to post your feature request there.
http://groups.google.com/group/google-checkout-developers-forum/web/new-feature-suggestions-for-google-checkout

Woody

Thanks Woodymon.
I sell true wholesale so profit margin is very small and I also offer free shipping on all domestic orders.
The low order fee is not for using a credit card to pay, but rather a convenience service fee for such a small order regardless of payment method.
I believe this is acceptable, I've literally seen thousands of merchants implementing something similar.
I did a few searches trying to find if this is a violation of the credit card companies' TOS, but I couldn't come up with anything. If you find something please let me know.

I hope ropu can come up with a solution. I'll leave it as it is for now, hopefully I won't get many small orders through GC and customers won't notice and abuse this loophole.

7 Apr 2007, 11:27 PM
#1064
spf avatar

spf

New Zenner

Join Date:
Jan 2007
Posts:
37
Plugin Contributions:
0

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

Woodymon:

Basic questions:

Are these errors occurring when your shop is setup with a Google Checkout sandbox account or a live/production account?

From your previous post regarding .htaccess issue it appears you are running PHP as CGI. Are you certain that is true? Your host can tell you.

If you are certain running PHP as CGI you can visit Ropu's site and use his generator to create an .htaccess file.
http://demo.globant.com/~brovagnati/tools/

When did your error occur? Immediately after you click the the GCO checkout image on your shop?

What does the error log report? response_error.php

What was the effect when you uninstalled authorize.net payment module? Any difference?

Woody

Now, I got it fixed. After created .htaccess and .hpasswd file, I forgot to switch folder back from 777 to 644 permission. So my server reject GCO access to that folder.

I still don't know how the error happened in the first place. My system was working before, until I installed authorize.net AIM. Then, GCO start timing out when trying to access responsehandler.php. That's the reason my merchant calculated shipping and coupon didn't work. I don't know what I did to fix it, other than re-installing GCO from payment module. While doing that, I ended up having sever 500 error. Now, everything is back to normal.. Thanks

8 Apr 2007, 6:11 AM
#1065
jay42 avatar

jay42

New Zenner

Join Date:
Mar 2007
Posts:
14
Plugin Contributions:
0

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

GCO UPS SHIPPING CALCUALTIONS NOT WORKING

Okay, 10 hours trying to implement this and reading every post from page 65 on, and I'm still just not getting it.

Here's my info: ZC 1.3.7, GCO v1.3RC1rev1, my host is definitely running PHP as CGI, and I am testing in the GCO Sandbox

I followed all instructions and installed GCO 1.3RC1rev1 manually updating files as instructed in the INSTALLATION file.

But in the README file, I do not understand the following:

"2. .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*). Set permission 777 for http://your-site/googlecheckout/ before running the script. Remember to turn back permissions after creating the files."

I found an earlier post that gave a link to Ropu's htaccess and htpasswd generators at http://demo.globant.com/~brovagnati/tools/htaccess.php

I entered my Merchant ID's and passwords, but I'm not sure what to enter at the:
"Absolute dir to googlecheckout/ : ( ie. /home/ropu/public_html/catalog/googlecheckout )"

I don't understand the example. So I entered http://www.mysite.com/googlecheckout and generated the files. I saved them in Notepad, changed the extensions to PHP, and then uploaded them to my /googlecheckout directory. Set the folder permissions at 777 before uploading them, then back to 744.

Here's what happens - I get the Google Checkout icon on my checkout page, I click it, log into the sandbox, and then the shipping goes to the default of 0.00. Using my normal checkout mode (manual processing of credit cards) instead of GCO, UPS rates calculate fine. FYI, I am only using UPS shipping, it is enabled in my payment modules, and I am pretty certain my error has to do with the htaccess and htpasswd files. Can someone please explain to me what directory to enter for the "Absolute directory", and exactly where to upload the htaccess and htpasswd files?

Sorry if this is a dumb question, but I just don't get it. Thanks for any help you can provide.

P.S. to Ropu -

In INSTRUCTIONS file, modification to tpl_checkout_payment_default.php file has the following lines:

// ** GOOGLE CHECKOUT **
// ** END GOOGLE CHECKOUT **

For some reason, these lines appear on the live customer Login page. I deleted them from the code and now they do not appear.

8 Apr 2007, 6:49 AM
#1066
jay42 avatar

jay42

New Zenner

Join Date:
Mar 2007
Posts:
14
Plugin Contributions:
0

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

Another issue....

But first, I think I may have found the directory name I was looking for in my previous post --- in the error message I got below! I generated a new htaccess and htpasswd file with the new directory, uploaded them to my googlecheckout folder, but still get default shipping rates in the GCO Sandbox. By the way, I forgot to mention this in my previous post, but I did set my ".htaccess Basic Authentication Mode" to "TRUE." Any ideas on why UPS shipping works in my normal checkout method of manually processing credit cards, but not in GCO?

But here is the new problem. When I get to my GCO sandbox customer account and I see the incorrect shipping rates, I decide to cancel my order. In GCO I click "Edit Order" and I am returned to my Zen Cart website. I click on the trash can to delete the item from my cart and get the following error:

// ** GOOGLE CHECKOUT **

// ** END GOOGLE CHECKOUT ** // ** GOOGLE CHECKOUT **
Fatal error: Cannot redeclare selfurl() (previously declared in /home/XXXX/XXXX/type/googlecheckout/gcheckout.php:38) in /home/XXXX/XXXX/type/googlecheckout/gcheckout.php on line 42

(I replaced the actual directory names above with XXXX for security purposes)

Is this a related error, or something else I need to worry about?

8 Apr 2007, 7:04 AM
#1067
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)

Jay42:

but I'm not sure what to enter at the:
Absolute dir to googlecheckout/ : ( ie. /home/ropu/public_html/catalog/googlecheckout) I don't understand the example. So I entered http://www.mysite.com/googlecheckout... Can someone explain to me what directory to enter for the "Absolute directory", and exactly where to upload the htaccess and htpasswd files?

It's very straightforward but yes it can get very confusing at the same time ;-)

  1. The absolute path to your shop is listed in your /includes/configure.php

  2. The readme says > 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.

So generally if you can run htaccess.php in your web browser doing so should automatically generate .htaccess and .htpasswd in the /googlecheckout directory.

But if you generate those two files with another tool then you need to manually upload the htaccess and htpasswd to your /googlecheckout directory. If you uploaded the mod package correctly, this directory should be in your shop directory (aka shop root).

  1. Note in the mod release the following three directories:
    /admin
    /includes
    /googlecheckout

Did you upload all directories?

  1. More detailed answer with example:

If your webroot directory is /home/account_name/public_html

And if you installed your shop directory in your webroot (this is typically standard location for most zen cart installs) then your shoproot directory would be /home/account_name/public_html/shop_name

(in this context 'catalog' and 'shop_name' and the shop root are synonymous. They just mean whatever directory you installed zencart into.)

BTW these directories above are referred to absolute directories as they describe the full "absolute" path from the root of your account, as opposed to a "relative" path. If this is still unclear, and you're not sure of the diff between an absolute vs. relative path, Google on the two terms. You will find simple explanations.

When you installed the Google Checkout mod, the googlecheckout directory should have been uploaded to the shop root. So you should have:
/home/account_name/public_html/shop_name/googlecheckout/

(this is an absolute path)

This is the directory which you should upload .htaccess and .htpasswd
if using Ropu's tool.

I agree that a bit more clarification in the readme of who should run /admin/htpasswd.php and who should run the provided tool on Ropu's site (and why the difference). And the readme should not include http:// to describe an absolute path.

Hope this helps.

Woody

8 Apr 2007, 9:25 AM
#1068
jay42 avatar

jay42

New Zenner

Join Date:
Mar 2007
Posts:
14
Plugin Contributions:
0

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

Thanks Woody,

I tried again, still not working. Here's part of my configure.php file:

// * DIR_FS_* = Filesystem directories (local/physical)
//the following path is a COMPLETE path to your Zen Cart files. eg: /var/www/vhost/accountname/public_html/store/
define('DIR_FS_CATALOG', '/home/Jay42/type/');
define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');
define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');
define('DIR_WS_UPLOADS', DIR_WS_IMAGES . 'uploads/');
define('DIR_FS_UPLOADS', DIR_FS_CATALOG . DIR_WS_UPLOADS);
define('DIR_FS_EMAIL_TEMPLATES', DIR_FS_CATALOG . 'email/');

I substituted Jay42 above for the real name for security purposes.

So in the "Absolute dir to googlecheckout" on Ropu's generator I entered:

/home/Jay42/type/googlecheckout

I pasted the code of each file in notepad, saved it as text, uploaded to my googlecheckout directory, renamed them to .htaccess and .htpasswd, and tested another sandbox order. Still, same problem....does not calculate UPS shipping, rather, uses default rates.

Did I get the directory name wrong? Or do something else wrong here?

Originally Posted by Woodymon
3. Note in the mod release the following three directories:
/admin
/includes
/googlecheckout

Did you upload all directories?

Yes, I followed all the instructions in the README and INSTALLATION files. As I currently have an existing checkout method (Credit Cards, manually processed), I followed OPTION B and uploaded all files in Section I and manually updated the 4 files in Section II.

Everything works except the UPS shipping calculations. So I feel the install was done correctly. Any additional advice would be appreciated. Thanks again for your help.

8 Apr 2007, 9:40 AM
#1069
theangel2g avatar

theangel2g

New Zenner

Join Date:
Mar 2007
Posts:
27
Plugin Contributions:
0

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

How do I make the below changes what files etc. I was referred back to Zen Cart for this information. I did the first part now I need help with the 2nd part.

Answer:
(This is a copy and paste from Jrox forum:)
actually, we've been approved for tracking.

In order to use JAM with Google Checkout, you need to contact Google and ask them to whitelist your domain.

Secondly, you will need to edit the shopping cart you are using with Google Checkout to add some XML code in it:

**http://code.google.com/apis/checkout/developer/checkout_pixel_tracking.html**

QUESTION: what file exactly to edit? Im using zen cart

Answer:
this is actually done on the shopping cart side, not JAM.

once we get more information on this, we'll post it.

9 Apr 2007, 4:28 AM
#1070
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)

Jay42:

define('DIR_FS_CATALOG', '/home/Jay42/type/');

So in the "Absolute dir to googlecheckout" on Ropu's generator I entered:

/home/Jay42/type/googlecheckout

I pasted the code of each file in notepad, saved it as text, uploaded to my googlecheckout directory, renamed them to .htaccess and .htpasswd, and tested another sandbox order. Still, same problem....

Appears you have knowledge of the proper absolute path. Thats all was trying to assist with. As to your mod issue will need to wait for ropu to chime in.

Good luck!

Woody

9 Apr 2007, 2:04 PM
#1071
r3volution11 avatar

r3volution11

New Zenner

Join Date:
Apr 2007
Posts:
4
Plugin Contributions:
0

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

ropu:

Hi nabrown

i don'y really know the cause of the issue

but this should solve it

replace in googlecheckout/gcheckout.php 38

function selfURL() {
$s = empty($_SERVER["HTTPS"]) ? '' : ($_SERVER["HTTPS"] == "on") ? "s" : "";
$protocol = strleft(strtolower($_SERVER["SERVER_PROTOCOL"]), "/").$s;
$port = ($_SERVER["SERVER_PORT"] == "80") ? "" : (":".$_SERVER["SERVER_PORT"]);
return $protocol."://".$_SERVER['SERVER_NAME'].$port.$_SERVER['REQUEST_URI'];
}

> 
> ```php
  if (!function_exists('selfURL')) {
    function selfURL() { 
      $s = empty($_SERVER["HTTPS"]) ? '' : ($_SERVER["HTTPS"] == "on") ? "s" : ""; 
      $protocol = strleft(strtolower($_SERVER["SERVER_PROTOCOL"]), "/").$s; 
      $port = ($_SERVER["SERVER_PORT"] == "80") ? "" : (":".$_SERVER["SERVER_PORT"]); 
      return $protocol."://".$_SERVER['SERVER_NAME'].$port.$_SERVER['REQUEST_URI']; 
    }
  }
```please send your feedbacks
> 
> hope this helps
> 
> ropu

After doing this I now get this error:

**Fatal error**:  Cannot redeclare strleft() (previously declared in /home/wilmersc/public_html/store/googlecheckout/gcheckout.php:44) in **/home/wilmersc/public_html/store/googlecheckout/gcheckout.php** on line **44

:|
**
9 Apr 2007, 2:06 PM
#1072
ropu avatar

ropu

Zen Follower

Join Date:
Oct 2006
Location:
argentina
Posts:
243
Plugin Contributions:
0

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

Greyboy:

ropu,

I just installed the 3RC1Rev1 version of GC and everything I am using is working perfectly. We have a site using CGI with the UPS shipping module installed. No defaults set for 1day air, 2day air and ground shipping and the calc callback is working great. Thanks so much for all your hard work. We are going live with this site this Thursday and I was starting to sweat.... Got the fix I needed just in the nick of time!

Thanks Again:clap:

BTW: Someone in this thread was asking if godaddy turbossl certs worked with GC. We have this cert and it works fine.
hi Greyboy

im happy to hear that!

:D

ropu

9 Apr 2007, 2:30 PM
#1073
r3volution11 avatar

r3volution11

New Zenner

Join Date:
Apr 2007
Posts:
4
Plugin Contributions:
0

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

I tried doing a if function on strleft and then it gave me this error:

Fatal error: Call to undefined function: strleft() in /home/wilmersc/public_html/store/googlecheckout/gcheckout.php on line 39

9 Apr 2007, 3:03 PM
#1074
r3volution11 avatar

r3volution11

New Zenner

Join Date:
Apr 2007
Posts:
4
Plugin Contributions:
0

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

BTW, this happens when I add something to the cart and then remove it. At least that's where I've noticed it so far.

9 Apr 2007, 3:23 PM
#1075
ropu avatar

ropu

Zen Follower

Join Date:
Oct 2006
Location:
argentina
Posts:
243
Plugin Contributions:
0

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.
Thx tj

added in the README file

ropu

9 Apr 2007, 3:26 PM
#1076
ropu avatar

ropu

Zen Follower

Join Date:
Oct 2006
Location:
argentina
Posts:
243
Plugin Contributions:
0

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

chain_man:

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!!

Hi chain_man!

in happy to hear that is working in an other Zencart e.commerce :D

ropu

9 Apr 2007, 3:29 PM
#1077
ropu avatar

ropu

Zen Follower

Join Date:
Oct 2006
Location:
argentina
Posts:
243
Plugin Contributions:
0

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

chain_man:

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,

Chain, please have a look to this post, there is explained how to get that button

http://groups.google.com/group/google-checkout-api-integration/browse_thread/thread/da5f4a838712d4c2/40c198e410602d59?lnk=gst&rnum=1#40c198e410602d59

hope this helps

ropu

9 Apr 2007, 4:05 PM
#1078
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:

Chain, please have a look to this post, there is explained how to get that button

http://groups.google.com/group/google-checkout-api-integration/browse_thread/thread/da5f4a838712d4c2/40c198e410602d59?lnk=gst&rnum=1#40c198e410602d59

hope this helps

ropu

Thanks Ropu -

I checked out that thread last week and made the suggested mods to my site. I guess it's up to Google now...

Welcome back!

9 Apr 2007, 4:39 PM
#1079
ropu avatar

ropu

Zen Follower

Join Date:
Oct 2006
Location:
argentina
Posts:
243
Plugin Contributions:
0

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

Hi all

as u can see im back again!

im glad to see that now we have 100+ post since i've been off..

i've read them all and i'll try to answer all of them, but its not possible in just one day. so please little patience!

also thx a LOT to woddy, bless chain, tj, for helping with this contrib!

well, stop chit chat, and start to work :D

ropu

9 Apr 2007, 10:45 PM
#1080
sojourner avatar

sojourner

New Zenner

Join Date:
Apr 2007
Posts:
1
Plugin Contributions:
0

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

My orders are showing up in the Customer Orders section and are listed as pending. When I log in to my sandbox account there are no orders there.

If I do https://www.mydomain.com/cart/googlecheckout/responsehandler.php

I see the following:
Mon Apr 9 15:37:02 US Mountain Standard Time 2007:- Invalid

Is that causing the problem?
I'm in Michigan so the time should be eastern time; however, I do not see where to change it in the admin section.

Other than no orders showing up in my sandbox account everything else seems to be working great. I go through the order process and the confirmation email is sent to my test user.

Misc Information about my setup:

I am testing using the sandbox for googlecheckout with the latest versions of zen-cart and googlecheckout. (downloaded from Ropu's sig)

I have activated the sandbox account and set the Integration settings to the following:

API callback: https://www.mydomain.com/cart/googlecheckout/responsehandler.php

Callback method: XML

Shopping cart post security checkbox is checked.

I do have SSL enabled.
I am on a shared windows server that has PHP4 and curl installed.
The MySQL 5 database is set to cache to the database.

Since I do not have the getallheaders function I had to comment out the security authentication checks. I did Ropu's recommendation of creating the .htaccess and .htpassword files.

I've checked for spaces in my merchant key and merchant ID and both look good. I got them from the sandbox account and double checked that I am not using my production keys.