Hi,
I have a HTML file stored as a part of my application.
I want to do a very simple modification to the content of the file.
Below is my HTML code. Pls look at line 6. You see the following script..
var myLatlng = new google.maps.LatLng(0,0);
Based on some conditions, I want to the change (0,0) to (10.2,11.5) or to some other value. Can somebody help me how to perform this. This is the only part I need to modify to different values based on certain circumstances.
<html>
<head>
<script src="</script">https://maps.googleapis.com/maps/api/js?sensor=false"></script>
<script type="text/javascript">
function load(){
var myLatlng = new google.maps.LatLng(0,0);
var mapOptions = {zoom: 15,center: myLatlng,mapTypeId: google.maps.MapTypeId.ROADMAP};
var map = new google.maps.Map(document.getElementById("map"), mapOptions);
var marker = new google.maps.Marker({,title:"Pole Location"});
marker.setMap(map);
google.maps.event.addListener(map, 'click', function(event){placeMarker(event.latLng);});
function placeMarker(location){
marker.setPosition(location);
document.getElementById("holder").innerHTML=location;
}
placeMarker(myLatlng);
}
</script>
</head>
<body onload="load()" style="margin:0px">
<div id="map" style="width: 515px; height: 505px"></div>
<div id="holder" ></div>
</body>
</html>