Questions tagged [postal-code]

A postal code is a series of letters and/or digits which is useful to identify the a particular region within a postal address. Once postal codes were introduced, other applications became possible.

A postal code is a series of letters and/or digits which is useful to identify the a particular region within a postal address. Once postal codes were introduced, other applications became possible.

In February 2005, 117 of the 190 member countries of the Universal Postal Union had postal code systems. Countries that do not have national systems include Ireland and Panama. Although Hong Kong and Macau are now Special Administrative Regions of China, each maintains its own long-established postal system, which does not utilize postal codes for domestic mail, and no postal codes are assigned to Hong Kong and Macau. Mail between Hong Kong, Macau and mainland China is treated as international.

399 questions
0
votes
1 answer

PHP partial postcode match

I am trying to create a simple postcode form where a users enters a postcode and if the postcode exists, the user is redirected to a link. So, I have this html form:
Razvan B.
  • 6,721
  • 2
  • 19
  • 32
0
votes
2 answers

Distance between postcodes code in full - But how can I have just 1 decimal place in distance?

I have an amazing piece of code that works out the distance between 2 postcodes in both; distance (miles), and driving time. The trouble now being - I am getting the distance in a very long form (eg: 10.2454014 miles) I just want it to just have 1…
Elaine Adams
  • 179
  • 10
0
votes
1 answer

How to get specific area name provided pincode of that area?

Is it possible to get info on subarea by providing pincode using google APIs? For example when I give pincode as 600020 it gives chennai as result, however this city contains pincodes from 600001 - 600132(approx). What I would like get from google…
bubble
  • 3,408
  • 5
  • 29
  • 51
0
votes
0 answers

Getting Lat Lon Co-ordinates based on full postcodes (Script conversion)

I have a website that uses UK postcodes lat and lon co-ordinates to allow members to search within a given distance but this only uses basic areas (LS2, WF1, etc). What I want to do is to get the lon/lat co-ordinates for the full postcode so that…
0
votes
1 answer

Are there any international address validation providers? trying to avoid google map api

I am being tasked to find a address validation engine for our company's database. The preferred method is through API feeds, and we are trying to avoid Google as it was deemed highly inaccurate for non-US address. We are looking for providers for…
J_Lo
  • 9
  • 1
  • 2
0
votes
1 answer

Validate UK short (outward) postcode

I'm using this validator: //validate postcode function IsPostcode($postcode) { $postcode = strtoupper(str_replace(' ','',$postcode)); if(preg_match("/^[A-Z]{1,2}[0-9]{2,3}[A-Z]{2}$/",$postcode) ||…
Adam
  • 1,957
  • 3
  • 27
  • 56
0
votes
2 answers

Calculate if listing is 'in range' from database values

Firstly I apologize for the Title! I couldn't think how to word it! I have a database with all the area codes in the UK with their average latitudes and longitudes. Now I want to be able to calculate which area codes are within 'n' miles from…
Adi Bradfield
  • 2,063
  • 1
  • 17
  • 27
0
votes
1 answer

Regex match UK postcode

I need to test a string and make sure its a valid UK postcode. My code currently works like this: var re = /GIR[…
CharliePrynn
  • 3,034
  • 5
  • 40
  • 68
0
votes
1 answer

Implementing postcode.nl API

At the moment I'm struggling with how to implement a api from postcode.nl. A Dutch initiative that helps you to get the street and city when a zipcode and housenumber is entered. Because the api is free to use, they don't give any support besides…
Timo002
  • 3,138
  • 4
  • 40
  • 65
0
votes
1 answer

Optimizing National ZIP+4 database for fast address lookup

I've just obtained a large set of text files (8 GB total) containing all of the address ranges within the U.S. The set consists of: 929 ZIP+4 files, each containing postal addresses of unique three-digit zip code. For example, file 606 would only…
user1185790
  • 623
  • 8
  • 24
0
votes
1 answer

CLGeocoder forward geocoding a postcode

I'm currently forward geocoding a postcode entered by the user via clgeocoder, however i'm getting some odd behaviour. If the user simply enters a single letter "p" for example, it can sometimes cause the app to become unresponsive, however in the…
SmokersCough
  • 967
  • 7
  • 22
0
votes
3 answers

Postcode Searching

Im not sure of the best way for getting what I am after so I will just explain it's application and hope a wiser person than me knows what i am in need of. I am after something pretty much the same as on www.Autotrader.co.uk where the user enters a…
0
votes
2 answers

Extract postcode from Google Maps API JSON using Google Refine

I'm trying to use Google Refine to extract postcodes from Google Maps API JSON. I added a new column by fetching URLs: "http://maps.googleapis.com/maps/api/geocode/json?sensor=false&address=" + escape(value, "url") Then the resulting JSON is as…
0
votes
1 answer

Perl to get location (longitude+latitude), plus post codes

There is this from another poster. (jpgunter)https://stackoverflow.com/users/1857927/jpgunter use strict; use LWP::Simple; # from CPAN use JSON qw( decode_json ); # from CPAN sub getLatLong($){ my ($address) = @_; my $format = "json"; #can…
0
votes
1 answer

mysql : using like return duplicate row count

i have an issue on the below table1 first case : postcode LS1 1LS second case: postcode LS11LS table2 postcode| region LS1 | Leeds LS11 | Leeds and i am using the below query to count the region versus related postcode SELECT…
Ahmed ElGamil
  • 179
  • 1
  • 13