Re: Google Checkout module for Zen Cart (beta)
thx limelites,
i have done a few other mods and all have gone quite smoothly but this one is very intimidating. the fact that u say the install is the ez part does not make it any more appealing.
i learned the importance of backups long ago. i will take the plunge and give it a shot but don't be surprised if i post here again!
thx again
Re: Google Checkout module for Zen Cart (beta)
I've seen a number of posts on this thread about why taxes aren't being calculated, but no resolutions. Any word or update on how to fix this. I'm having the same problem.
Thanks,
Re: Google Checkout module for Zen Cart (beta)
right im trying AGAIN to install GC on my store and yet again still cant get the postage to work.
i use google zone table rates modual for shipping so local people can get free delivery, mainland uk get a set price and offshore and nonmainland/highlands get the same as UK plus £10.
Default Values for Real Time Shipping Rates
Default values for real time rates in case the webservice call fails.
Set Default Value to 0 to disable the method
shipping generator
Zones Table Rate zonetable not configured!
i have tried the shipping generator in the Admin cuntrol panel for GC but this gives totally random figures totally different to my shipping modual.
do i need to install a different shipping modual like one of the standard zc moduals and install google checkout postage that way???
Please help. This is the 2nd time ive tried to install this and still cant get it working.
Re: Google Checkout module for Zen Cart (beta)
I see you're in the UK? I am too. I had difficulty getting GC to work with my ZC shipping modules too. I ended up having to force flat rate shipping for all GC orders.
This can be done rather easily. Simply enter Allow US PO BOX shipping ...... set to FALSE and just enter the flat rate for the shipping methods into the boxes provided below this....
You'll also need to set GoogleCheckout Carrier Calculated Shipping to false.
Re: Google Checkout module for Zen Cart (beta)
I've seen that this issue has been going on for quite sometime but I just can't find a fix.
I came across this error when I put something in my cart- viewed the cart and then removed the item from the cart:
Fatal error: Cannot redeclare selfurl() (previously declared in /home/XXXXX/public_html/googlecheckout/gcheckout.php:39) in /home/XXXXX/public_html/googlecheckout/gcheckout.php on line 38
I found some hints and made this change:
replace in googlecheckout/gcheckout.php 38
PHP Code:
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'];
}
with this
PHP Code:
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'];
}
}
Now I have this error when I empty the shopping cart when looking at it:
Fatal error: Cannot redeclare strleft() (previously declared in /home/XXXXX/public_html/googlecheckout/gcheckout.php:46) in /home/XXXXX/public_html/googlecheckout/gcheckout.php on line 46
FYI: Lines 46- 48 are:
function strleft($s1, $s2) {
return substr($s1, 0, strpos($s1, $s2));
}
When I posted this on the Google support forum, I received this answer but I don't know what to make of it:
Any error which states "Cannot redeclare" means the function has already been defined somewhere in the code being parsed.
Try having functions all in one place and not repeating them, or wrapping them in the if (!function_exists('FUNCTION_NAME')) { logic.
Any help would be greatly appreciated.
Nancy
Re: Google Checkout module for Zen Cart (beta)
You should try removing the GC mod completely, then re-installing.
Re: Google Checkout module for Zen Cart (beta)
Well, I have completely reinstalled and now I'm back to:
Fatal error: Cannot redeclare selfurl() (previously declared in /home/xxxxx/public_html/googlecheckout/gcheckout.php:39) in /home/xxxxx/public_html/googlecheckout/gcheckout.php on line 38
Any other thoughts??
Nancy
Re: Google Checkout module for Zen Cart (beta)
previously declared in /home/xxxxx/public_html/googlecheckout/gcheckout.php:39) in /home/xxxxx/public_html/googlecheckout/gcheckout.php on line 38
What does it say on line 38?
Re: Google Checkout module for Zen Cart (beta)
Quote:
Originally Posted by
limelites
previously declared in /home/xxxxx/public_html/googlecheckout/gcheckout.php:39) in /home/xxxxx/public_html/googlecheckout/gcheckout.php on line 38
What does it say on line 38?
Lines 38 thru 45:
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'];
}
function strleft($s1, $s2) {
return substr($s1, 0, strpos($s1, $s2));
I can make that error go away by changing:
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'];
}
to
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'];
}
}
and that's when I get this error:
Fatal error: Cannot redeclare strleft() (previously declared in /home/XXXXX/public_html/googlecheckout/gcheckout.php:46) in /home/XXXXX/public_html/googlecheckout/gcheckout.php on line 46
I promise that I have really tried (and tried) to fix this!!
Thanks
Nancy