Advanced Maps

I need to implement a map which would show several locations (let’s say initially only 2). Fhe 1st and 2nd location would be a traveling starting and ending point. I need to present pushpins, calculate the distance (possibly let users click for directions).

I would also like to know it anybody have had any success woorking directly with GPS positioning to show the gps locations in real time. I think I’ve seen some posts but looks like all those are still open questions.

This? https://developers.google.com/maps/documentation/javascript/examples/marker-simple
This should show all you need. You need a developer key tho (it is free tho limited to a certain amount of requests per 24 hour).