Local event search using postcodes
-
Hi. I was wondering if there is a way to list ALL the postcodes so that I can use them to make a local event search with Google maps.
I found this code online
<!DOCTYPE html> <html> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8"/> <title>Google Maps API Geocoding Demo</title> <script src="https://maps.google.com/maps?file=api&v=2&sensor=false" type="text/javascript"></script> </head> <body onunload="GUnload()"> <div id="map_canvas" style="width: 400px; height: 300px"></div> <script type="text/javascript"> var geocoder = new GClientGeocoder(); var map = new GMap2(document.getElementById("map_canvas")); var i; var postcodes = [ 'SL59JH', 'LU13TQ', 'SR29TD', 'DA75BQ', 'EC1V9B' ]; map.setCenter(new GLatLng(54.00, -3.00), 5); for (i = 0; i < postcodes.length; i++) { geocoder.getLatLng(postcodes[i] + ', UK', function (point) { if (point) { map.addOverlay(new GMarker(point)); } }); } </script> </body> </html>
where it says ` var postcodes = [
‘SL59JH’,
‘LU13TQ’,
‘SR29TD’,
‘DA75BQ’,
‘EC1V9B’
];`
is it possible to call all of the EMPostcodes to fit inside that array?
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Local event search using postcodes’ is closed to new replies.