I want to retrieve latitude and longitude from my database and show them as maker on Google Map. I learned it from Google Maps JS API v3 - Simple Multiple Marker Example. But in this example, the latitude and longitude is assigned by user. I want to know if I have already retrieved my lat&long from my database, for example in php, $lat $long
, how to assign them into a list like this:
var locations=[[..,..],[..,..],[..,..]]
//$lat is the first parameter and $long is the second.
Many thanks!