Forums / Addon Payment Modules / Google Checkout and Free shipping - SOLUTION HERE

Google Checkout and Free shipping - SOLUTION HERE

Locked

Views: 7,125

Results 1 to 9 of 9
This thread is locked. New replies are disabled.
15 Dec 2008, 5:28 AM
#1
greenhat avatar

greenhat

Zen Follower

Join Date:
May 2007
Posts:
108
Plugin Contributions:
0

Google Checkout and Free shipping - SOLUTION HERE

Problem:
If "Free shipping options" method is enable in ZC, GC makes all shipping free (including the ones you dont want) if responsehandler times out (which happens quite often).

After spending a night searching for a solution and reading through dozens of posts, i finally decided to try to hack it myself.

Solution:

edit file /store/googlecheckout/gcheckout.php

insert the following code to line 462:

        //BEGIN: Hack to remove FreeOptions shipping 
    // FreeOptions shipping is removed from the list of shipping methods available to Google Checkout 
    // if it does not meet the Free shipping criteria (variable $price is not set by the quote() function).
    if($curr_ship == "FREEOPTIONS"){
            $module = new $module_name;
            $quote = $module->quote();
            $price = $quote['methods'][0]['cost'];
            if (is_null($price)) {
                $enable = "False";
                unset($module_info_enabled['FREEOPTIONS']);
            }
        }
    //END: Hack to remove FreeOptions shipping 
            
        

or just replace your file by the one attached.

The code removes FreeOptions shipping from the list of shipping methods available to Google Checkout if it does not meet the Free shipping criteria.
I implemented this on ZC v1.3.7 with GC v1.45 and it works well.
Good luck!

15 Dec 2008, 5:37 AM
#3
misty avatar

misty

Inactive

Join Date:
Apr 2004
Location:
UK
Posts:
5,752
Plugin Contributions:
1

Re: Google Checkout and Free shipping - SOLUTION HERE

Why not also post this in Google Checkout thread..
Single posts are not always found by zencart forum
members...

Dezina ZenCart Templates
Please do not PM for support queries..Post in forums..help others

15 Dec 2008, 5:41 AM
#4
greenhat avatar

greenhat

Zen Follower

Join Date:
May 2007
Posts:
108
Plugin Contributions:
0

Re: Google Checkout and Free shipping - SOLUTION HERE

I am about to post a reference to this thread there. GC thread is really huge and it's too easy for a solution to get lost there.

27 Jul 2009, 4:10 AM
#6
gibbywmu avatar

gibbywmu

New Zenner

Join Date:
May 2008
Posts:
21
Plugin Contributions:
0

Re: Google Checkout and Free shipping - SOLUTION HERE

Thanks a bunch! I've been screwing around with this for hours, and I finally got it to work! Now the FREE SHIPPING options only show up like I have it set on Zen Cart, for orders over $25,. Sure do appreciate the coding fix!

30 Dec 2009, 11:15 PM
#7
new2u avatar

new2u

Zen Follower

Join Date:
Sep 2009
Posts:
186
Plugin Contributions:
0

Re: Google Checkout and Free shipping - SOLUTION HERE

This fix wont work with the latest version.... back to square 1

31 Dec 2009, 8:22 PM
#8
new2u avatar

new2u

Zen Follower

Join Date:
Sep 2009
Posts:
186
Plugin Contributions:
0

Re: Google Checkout and Free shipping - SOLUTION HERE

It looks like it isnt timing out for me anymore and the free shipping options aren't shown ever now. Make sure to edit out any shipping methods youa re not using in the shipping_methods.php file... it helps speed this up.

30 Jun 2010, 12:36 AM
#9
tawnos avatar

tawnos

New Zenner

Join Date:
Apr 2010
Posts:
44
Plugin Contributions:
0

Re: Google Checkout and Free shipping - SOLUTION HERE

You are my hero! thanks :D