On Apr 30, 9:23 am, Matt <[email protected]> wrote: > I have a feeling that will produce the same output as my current code > though, eg, it will get the correct lat/lng values, but plot new A and > B markers at those locations, rather than using my existing ones. Am I > right?
That is correct. That is the problem with providing psuedo code, and not providing links... One way of preventing it from overlaying the markers is to manually add the polyline. > > On Apr 30, 5:17 pm, "[email protected]" <[email protected]> > wrote: > > > > > On Apr 30, 8:39 am, Matt <[email protected]> wrote: > > > > Hi all, > > > > More of a theoretical question than a specific one here. > > > > I have a map where the user clicks to set their 'home' location, and > > > are then presented with a list of nearby events. They can click on > > > these events to see them placed on the map. The info windows for the > > > markers contain a 'directions to here' link which I want to generate > > > directions from their home point to this marker for. > > > > At the moment I have some code that does this, but it creates new > > > markers for each end, which seems pointless since I already have > > > markers for both already. Ideally, I just want to do something like > > > (psuedocode): > > > > gDir.load("from: marker1 to: marker2); > > > > rather than specifying the lat/lng again. > > > > Is this possible? > > > Yes. > > (psuedocode): > > > gDir.load("from: "+marker1.getLatLng()+" to: "+marker2.getLatLng()); > > > > Thanks > > > Matt- Hide quoted text - > > - Show quoted text - --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Maps API" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/Google-Maps-API?hl=en -~----------~----~----~----~------~----~------~--~---
