javascript geo location

by Marvin Villanueva

HTML

<script src="http://www.geoplugin.net/javascript.gp"></script>
<input type='button' id='btnShow' value='Show my location' onclick='' />

JavaScript

$(function(){

    $('#btnShow').click(function(){
        alert('IP: ' + geoplugin_request() + '\nLatitude: ' + geoplugin_latitude() + '\nLongtitude: ' + geoplugin_longitude() + '\nCity: ' + geoplugin_city() + '\nRegion: ' + geoplugin_region() + '\nCountry: ' + geoplugin_countryName());    
        
    });
});