0

私は Google Fusion Tables/Maps を使用する初心者です。会社名と住所が記載されたビジネス名簿があります。それぞれの場所のジオコード マップ マーカーを取得して、テーブルの [施設名] 列と並べて表示できます。ユーザーが会社/施設名をクリックして、マップ内のその施設の特定のマップ マーカー情報ボックスにジャンプできるように、施設名をコーディングするにはどうすればよいですか? どんな助けでも大歓迎です!

4

1 に答える 1

1

Once the user clicks on the company name, you can create a new InfoWindow object manually. Then set it's position and content and finally put it on the map:

 var map = new google.maps.Map(document.getElementById('map-canvas');
 var infoWindow = new google.maps.InfoWindow();
 var coordinates = new google.maps.LatLng(37.5, -122.1);
 infoWindow.setPosition(coordinates);
 infoWindow.setContent('Company/Facility XY');
 infoWindow.open(map);

There is an InfoWindow example from Google, that even uses geocoding and a spatial query to get the closest hit from the database.

于 2012-08-05T21:33:33.593 に答える