Jump to content
chipshi11

Postcode UK delivery

Recommended Posts

So, we're getting somewhere. It's almost done so a special thanks to @@Mort-lemur for the help. The pics made a big difference! Just one more thing (I hope!). I've got it working so far for outside Merseyside, but the zone for outside Merseyside contained just one zone 'all zones'. I assumed it would pick this one unless they were inside Merseyside, in which case it would choose the cheaper one for within Merseyside as it's now an option but even in Merseyside it's giving me the price for outside because it's listed as 'all zones'. Is there a way to set a tax zone up as all zones EXCEPT one or do I now need to add every other county in England manually?

Share this post


Link to post
Share on other sites

@@chipshi11 This will add all the UK counties to your database: http://addons.oscommerce.com/info/8948 (remember to make a backup first just in case)

 

Then add the counties to the shipping zones such as:

 

Shp: Liverpool (would just contain Liverpool)

Shp: Highlands (Scottish highland counties + Scottish islands)

Shp: England (all other counties not in the above two)

 

I think the counties list is almost complete - I think I had to add a couple of odd-balls since I set up my county list


Now running on a fully modded, Mobile Friendly 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.

Share this post


Link to post
Share on other sites

Hi just seen this thread whilst browsing through things, it's probaly not much help to @@chipshi11 now but hopefully this may help anyone else with this issuse who reads this.

 

There is an addon for UK postcode shipping, it's made for v2.2 - UK Postcode based carrier shipping


 

Hopefully this can be modified to 2.3.4 as I hope to use it, I have it installed on a 2.2 site and with a bit of tweaking can support different carriers (by modifying the name of the module etc.)

 

The hardest part is getting a current list of the outbound postcodes as it's a heavily guarded Royal Mail asset - paid for by the general public !

 

A fairly up-to-date copy of the postcode list can be found at the Office for National Statistics - click here - and search for 'postcode'

The problem with this link is that it contains every postcode along with the location data (great if your writing a navigation app B) ), so it needs a bit of parsing as it's only 1.21Gb small (uncompressed)

 

Alternatively ask your carrier if the have a postcode to charge zone list that you can import.

 

If anyone wants anymore info please feel free to pm me.

 

Share this post


Link to post
Share on other sites

 

There is an addon for UK postcode shipping, it's made for v2.2 - UK Postcode based carrier shipping

 

Sorry to drag up a bit of an old thread, but there never has been a shipping module for the UK that really worked for me either, so had to modify the one listed above to suit my needs.

 

You don't need a full postcode file, you use a table in the database with all the first halves of all the UK postcodes (AB1,AB2,AB3,etc...), of which I am currently using 2986, and assign each of those to a zone number to match whatever courier you are using.

 

The main problem with the contribution listed above is that it only worked if the postcodes were correctly formatted, but not everyone types them in upper case with a gap in the middle, so didn't always work.

 

I used a postcode regex I found elsewhere so that it splits the postcode regardless of how its entered, gap/no gap, uppercase/lowercase (ab123cd, ab12 3cd, AB123CD, AB12 3CD, Ab12bCd) and just gives you the first half of the postcode back formatted correctly to check against a zone in your db.

 

No need for huge drop down lists of all UK counties, it simply uses the customers postcode, or a postcode typed into the box on the ship in cart estimator.

 

It also give people the option of doing free shipping in their own postcode area (or list of selected postcode areas), if you do your own deliveries locally.

Share this post


Link to post
Share on other sites

@@Enzo_UK

I use the addon you mention, and it also has a script to format the post code correctly, when the submit button is clicked.  This checks the postcode, even for London codes, and stores under letters too.

 

What is the regex you use, and how do you implement it?


osC BS gold live - osC CE in development (awesome)

Share this post


Link to post
Share on other sites

 

I use the addon you mention, and it also has a script to format the post code correctly

The one that came with it didn't work properly for me, it only worked if people typed the postcode in with the gap in it, as think that's just where it does some sort of preg split.

 

So if someone just put in AB12 it worked, and if you put in AB12 3CD it worked as splits it using the gap.

 

If someone enters AB123CD with no gap it throws an error.

 

Check yours, as that's what happened in mine, and was why I had to find another way.

Share this post


Link to post
Share on other sites

@@Enzo_UK

strange, on my system AB123CD splits into AB12 3CD

 

I've checked, as AB12 is used to define local delivery


osC BS gold live - osC CE in development (awesome)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×