Re: [請益] Google map輸入住址後直接show map的應用

看板Google (谷歌Google)作者 (Doenkiss)時間16年前 (2009/09/12 01:22), 編輯推噓1(105)
留言6則, 1人參與, 最新討論串2/2 (看更多)
之前做專案的時候有找過相關的資訊,不知道是不是你要的效果 function showAddress(address) { if (geocoder) { geocoder.getLatLng( address, function(point) { if (!point) { alert("很抱歉,我們找不到"" + address + ""這個地址。"); } else { map.setCenter(point, 15); var marker = new GMarker(point); } } ); } } -- <form action="#" onsubmit="showAddress(this.address_sreach.value); return fal se"> <input type="text" name="address_sreach" value=""/> <input type="submit" value="Go!"/> </form> -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 61.57.129.247 ※ 編輯: doenkiss 來自: 61.57.129.247 (09/12 01:23)

09/13 14:37, , 1F
謝謝您的回答,但這是在已經有google map的網頁中使用的
09/13 14:37, 1F

09/13 14:38, , 2F
小弟要的是,在店家註冊資訊中填寫店家的住址之後,系統
09/13 14:38, 2F

09/13 14:38, , 3F
會自動找到此店家地址在google map上的位置,也就是HTML
09/13 14:38, 3F

09/13 14:39, , 4F
的語法<iFrame>....</iFrame>,會這麼做的需求是讓使用者
09/13 14:39, 4F

09/13 14:40, , 5F
不用自行到google map上找尋自己位置的HTML語法,來減輕
09/13 14:40, 5F

09/13 14:40, , 6F
使用者的負擔,謝謝。
09/13 14:40, 6F
文章代碼(AID): #1AgeTHcW (Google)
文章代碼(AID): #1AgeTHcW (Google)