fri3ndly Posted August 29, 2008 Share Posted August 29, 2008 Please can someone help me with this? There is no javascript error but the marker is not showing :-( <script type="text/javascript"> //<![CDATA[ function load() { if (GBrowserIsCompatible()) { var map = new GMap2(document.getElementById("map")); map.setCenter(new GLatLng(51.518994, -0.133457), 17); map.addControl(new GLargeMapControl()); map.addControl(new GScaleControl()); map.addControl(new GMapTypeControl()); var point = new GPoint(parseFloat(51.518994),parseFloat(-0.133457)); var marker = new GMarker(point); map.addOverlay(marker); } } //]]> </script> Quote Link to comment Share on other sites More sharing options...
fri3ndly Posted August 29, 2008 Author Share Posted August 29, 2008 Solved: <script type="text/javascript"> //<![CDATA[ function load() { if (GBrowserIsCompatible()) { var map = new GMap2(document.getElementById("map")); map.addControl(new GSmallMapControl()); map.addControl(new GMapTypeControl()); map.setCenter(new GLatLng(51.518994, -0.133457), 17); var marker = new GMarker(map.getCenter()); map.addOverlay(marker); } } //]]> </script> Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.