how to code to get current location name based on longitude and latitude in javascript? : i m using this code to get the current location of the user through google maps api and i am getting the location in the form of latitude and longitudes and getting the location in LatLng variable. But after that when i am converting the latitude and longitude to an address then its not working . Kindly help....
        
       if (navigator.geolocation) 
             {
                navigator.geolocation.getCurrentPosition(function (p)
                 {
        	 

                var LatLng = new google.maps.LatLng(p.coords.latitude,p.coords.longitude);
             alert(LatLng);
             alert(p.coords.latitude);
             alert(p.coords.longitude);
             
             var mapOptions = {
             		 
                 center: LatLng,
                 zoom: 13,
                 mapTypeId: google.maps.MapTypeId.ROADMAP
             
             };
            
             var geocoder = new google.maps.Geocoder();
            
             geocoder.geocode({ 'LatLng': LatLng }, function (results, status)
            		 {
            	 alert(geocoder);	
                
            	 if (status == google.maps.GeocoderStatus.OK)
            		 {
            		 if (results[1])
            			 {
            			 alert("Location: " + results[1].formatted_address);
            			 }
            		 }
            		 });
             
        