Thursday, 12 June 2008

WEB: Google Maps - finding the GLatLng setting

Note: Unless you?re a website designer, this probably won?t mean a lot to you!

Need to find out your ?GLatLng? settings for a custom Google Maps implementation? The code looks something like this...


"function load() {
if (GBrowserIsCompatible()) {
var map = new GMap2(document.getElementById("map"));
map.setCenter(new GLatLng(37.4419, -122.1419), 13);
var gIcons = [];
map.addControl(new GSmallMapControl());
map.addControl(new GMapTypeControl());
map.openInfoWindow(map.getCenter(),
document.createTextNode("Where I want to be"));
}
}"


The trouble is, by default it is pointed to Santa Paula or similar and you can't use a UK postcode or similar to centre the map where you want it. You need the true Latitude and Longitude figures which are often a little hard to come by. Michelin to the rescue...

Head over to the Via Michelin website: http://www.viamichelin.co.uk/viamichelin/gbr/tpl/hme/MaHomePage.htm

1. Choose your country
2. Enter the postcode
3. From the resultant window on the left, choose the 'Send via GPS' option
4. Choose 'Garmin' for the GPS type
5. Name the file in the next box (e.g. 'test') and click 'OK'
6. Save the file produced to your desktop
7. Open the *.gpx you just saved in Textedit (Mac) or Editplus (win) or similar and look for the latitude and longitude numbers. They will be near the bottom and look something like:
8. In your web code, replace the default longitude and latitude settings with those in the file. However, Google only excepts values to 4 decimal places so make '53.4776593' into '53.4776' and also remember that the longitude will have a '+' or '-' before it - don't forget that.
9. Save and upload your amended web file and you should be centred exactly where you want to be.

Labels: , ,

Friday, 19 October 2007

GPS: Why no digital mapping for OSX?


After one too many bike rides where the party ended up lost, we have invested in a nice shiny Garmin Etrex HC. The plan is simple: download existing mountain bike routes to Etrex, clip Etrex to handlebars, party follows direction arrow on Etrex and a good day (that doesn't involve stopping to check a map non of us can read every 10ft) is had by all.

One fly in the ointment is that there are no OSX based digital mapping solutions that accept ordnance survey maps. There are a few for the PC: Memory Map and Tracklogs to name two - but non that will run under OSX. So until such a program is released I'll be forced to get something to run on my Windows machine...

I am, to say the least, rather baffled by the lack of OSX support, especially during the current Apple renaissance. However, anyone who has tried to make sense of the Garmin manuals or website is probably keeping their fingers crossed they don't make any software for the Mac!

Labels: , ,

Tuesday, 8 May 2007

GPS: Starbuck Point Of Interest file (Tom Tom)


I made this last year and forgot to post up. It's a Points Of Interest file (POI) for all Starbucks shops in the UK. If you have a Tom Tom GPS device just download the zip file and copy the two files (excluding the 'readme') onto your Tom Tom device and hey presto! Instant Latte on the move.

If you've found this useful, be a sport and send me enough for a Latte on paypal (paypal address is ben@frain.freeserve.co.uk).

Here is the Zip file, cheers :)

Labels: , , ,

© benfrain.com 2007-2008 | UK Based Freelance Writing and Web Design