Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9064867
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T16:21:48+00:00 2026-06-16T16:21:48+00:00

Hi i have been using this code to show multiple location on a google

  • 0

Hi i have been using this code to show multiple location on a google map and also dropping pins on each location.

var mylocation = new google.maps.LatLng(52.520816, 13.410186);

var neighborhoods = [
new google.maps.LatLng(52.511467, 13.447179),
new google.maps.LatLng(52.549061, 13.422975),
new google.maps.LatLng(52.497622, 13.396110),
new google.maps.LatLng(52.517683, 13.394393)
];

var markers = [];
var map;

function initialize() {
var mapOptions = {
zoom: 12,
mapTypeId: google.maps.MapTypeId.ROADMAP,
center: mylocation
};
map = new google.maps.Map(document.getElementById('googleMap'),
mapOptions);
drop();
}

function drop(){
for (var i = 0; i < neighborhoods.length; i++) 
{
markers.push(new google.maps.Marker({
position: neighborhoods[i],
map: map,
}));
}

}

what i want is to show info window on all the pins showing their respective lats and lngs

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T16:21:49+00:00Added an answer on June 16, 2026 at 4:21 pm
    function drop()
    {
     for (var i = 0; i < neighborhoods.length; i++) 
     {
       var marker= new google.maps.Marker({
       position: neighborhoods[i],
       map: map,
       });
      var infoWindow = new google.maps.InfoWindow({content:marker.getPosition()});
      infoWindow.open(map, marker);
     }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been using this code here: $(document).ready(function(){ $('a[href*=#]').bind('click', function(){ var $href = $(this).attr('href')
I have been using this code to implement a Popup JDialog of sorts, like
I have been using this code, but have been running into some memory issues:
I have been using this code with great success to pull out the first
Hi I have been using this code to fetch data from mysql database and
I am having trouble getting this code to run using Google Chrome(I have not
I have been using this link to learn about multiprocessing, but I'm stuck on
I have been using this copy method for quite a while, in lots of
I have been using this as a reference, but not able to accomplish exactly
I have been using this so far system 'strings binary-file.dmp | grep search_string' Is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.