Hi,But that doesn't sort out the weight used for calculating postage :(
I'm going to have to turn off all international postage until this gets sorted out.
Good luck with your own site.
Best regards
Alan
Printable View
or you could not offer free options ! I've just sold my first lens caps to Denmark from the site which isn't live yet, I'd turned off the security for exactly 16 hours to do some paypal testing, and so the site is already "launched" but I won't be actively promoting it until next week, so I may have some time.
This is just to confirm that big_royalmail_v2.0 works on Zencart 1.3.5 and the 1.3.6 updated version.
Bit of a newbie here, so I apologise if this issue's been raised before (I couldn't find it on a search). I've only been using zencart for a couple of weeks but, together with this Royal Mail Shipping Module, it's been great despite the learning curve.
The problem I have is with the Standard Parcels bit of this module. It works fine until you get to a weight that's over 6Kg - then it won't offer Standard Parcels as an option.
I've trawled through the code and think I've figured out where the problem is - well, I think I know how to solve it.
The shipping rates are listed at:
1:3.85
1.5:4.95
2:5.31
4:4.70
6:8.74
8:9.97
10:10.70
20:12.46
It seems to me that the code only looks at the first 5 weights (1, 1.5, 2, 4 and 6kg) and not the other three (8, 10, and 20kg). That's if I'm reading the code correctly. For example, rmstdparcels100.php shows:
but in the SQL database there areCode:$zones_cost = constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST0_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST1_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST2_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST3_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST4_' . $dest_zone);
MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST0_1
MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST1_1
MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST2_1
MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST3_1
MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST4_1
MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST5_1
MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST6_1
MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST7_1
This applies equally to the other Std Parcels modules. It seems to me that adding the other three (ZONES_COST5, ZONES_COST6, and ZONES_COST7) into the code would fix it but, being a bit green at this, I don't want to fiddle with the code. The easiest solution is to put multiple values in the first five boxes and leave the remaining three empty, i.e.:
1:3.85, 1.5:4.95, 2:5.31
4:7.70, 6:8.74, 8:9.97
10:10.70
20:12.46
(other boxes left blank)
Now the shipping estimator show shipping prices for weights over 6Kg.
Hope this helps someone.
JSR
At first glance it looks like you are perfectly correct so I wouldn't call you a newbie, I have another release coming up very soon with a few minor bug fixes and an improvement to the courier shipping, so I'll have a look but I'm in and out of hospital at the moment, so I reckon probably Monday for a permanent fix.
@JSR:
Oops! - well spotted, you're absolutely right.
And that's my fault rather than Philip's - I must have sent him the half-done files instead of the completed ones (the ones I have installed work fine) :blush:
The changes are as you suggested:
In rmstdparcels:
Around line 107 you need to have:
PHP Code:
$zones_cost = constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST0_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST1_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST2_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST3_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST4_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST5_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST6_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST7_' . $dest_zone);
and around line 169 you need to have:
PHP Code:
$zones_cost = constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST0_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST1_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST2_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST3_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST4_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST5_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST6_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS_ZONES_COST7_' . $dest_zone);
In rmstdparcels100:
Around line 107 you need this:
and around line 169:PHP Code:
$zones_cost = constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST0_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST1_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST2_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST3_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST4_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST5_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST6_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST7_' . $dest_zone);
PHP Code:
$zones_cost = constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST0_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST1_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST2_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST3_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST4_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST5_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST6_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS100_ZONES_COST7_' . $dest_zone);
In rmstdparcels250:
Around line 107:
And around line 169:PHP Code:
$zones_cost = constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST0_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST1_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST2_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST3_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST4_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST5_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST6_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST7_' . $dest_zone);
PHP Code:
$zones_cost = constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST0_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST1_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST2_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST3_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST4_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST5_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST6_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS250_ZONES_COST7_' . $dest_zone);
In rmstdparcels500:
Around line 107:
And around line 169:PHP Code:
$zones_cost = constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST0_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST1_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST2_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST3_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST4_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST5_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST6_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST7_' . $dest_zone);
Hopefully that should be right (now) - my apologies Philip. :smile:PHP Code:
$zones_cost = constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST0_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST1_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST2_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST3_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST4_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST5_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST6_' . $dest_zone)
. ',' . constant('MODULE_SHIPPING_RMSTDPARCELS500_ZONES_COST7_' . $dest_zone);
I'm just glad I was able to help.
I was tempted to just post the question when I first noticed it but I figured it'd be far more helpful if I could find the solution myself. After all, you and Philip (and whoever else) have done so much great work on this module already. It's good to be able offer a solution instead of just another problem.
If I run into anything else, you'll be the first to know! :D
Regards.
JSR
The latest version with JSR's modifications and an improvement to the UK courier shipping module has been submitted and should shortly be available from the downloads section, but as normal it is also released here:
http://bouncing.org/big_royalmail_v2.1.zip
Thank you for spotting that JSR and this thread has temporarily stopped sending me notifications of new messages, so thanks Pixxi, I did exactly the same as you.
I'd like to congratulate the author and other contributors for this excellent module. I'm in the UK and wanted a regional split to reflect courier rates. This does it. A big thanks.
One thing I've noticed, though (on a test site), is that when someone registers, the drop down menu lists shows each county twice, and I think I see why in the optional county install sql file. All the UK counties are entered, and then entered again for the regional splits.
Is there a particular reason for this? Is there a way I can take out those duplications? (Arran actually appears four times in the drop down).
Patrick