Tag Archives: Map

loop through array in ES5

If you’re using an environment that supports the Array features of ES5 (directly or using a shim), you can use the new forEach function: var a = [“a”, “b”, “c”]; a.forEach(function(entry) { console.log(entry); }); forEach accepts an iterator function and, optionally, a value to use as this when calling that iterator function (not used above). The iterator function is called for each […]


Show Your Current Location in Map using Navigator Object

Hello Friend’s, Here we will see how to display your current location in map using javascript navigator object. The navigator object contains information about the browser. We need one button control, one label / div or anything to show current co-ordinates that is longitude and latitude and one div tag to show map on page. […]