geolocation

Can we locate a user via user's phone number in Android?

蓝咒 提交于 2019-12-03 07:40:18
问题 Is it possible to locate a user via user's phone number in Android? If an SMS can be sent to the user then we can also retrieve or get to know the location of the user who we sending the SMS. I mean is it possible to program the following functionality: App sends SMS to user's phone App recieves SMS at user's phone from the SMS sender App gets location coordinates of the user's phone App sends location coordinates to the SMS sender via SMS Also is it possible to retrieve the required location

Reverse wikipedia geotagging lookup

倾然丶 夕夏残阳落幕 提交于 2019-12-03 07:24:49
问题 Wikipedia is geotagging a lot of its articles. (Look in the top right corner of the page.) Is there any API for querying all geotagged pages within a specified radius of a geographical position? Update Okay, so based on lost-theory's answer I tried this (on DBpedia query explorer): PREFIX geo: <http://www.w3.org/2003/01/geo/wgs84_pos#> SELECT ?subject ?label ?lat ?long WHERE { ?subject geo:lat ?lat. ?subject geo:long ?long. ?subject rdfs:label ?label. FILTER(xsd:float(?lat) - 57.03185 <= 0.05

Detecting whether location services are enabled for my app

99封情书 提交于 2019-12-03 07:24:47
问题 I'm developping my first iOS app, and this uses the user's location. I know that the device asks the user whether to enable location services for the app, but how do I know if the user has enable it or not? 回答1: Probably [CLLocationManager authorizationStatus] != kCLAuthorizationStatusDenied should be the answer releated SO questions are: Checking for iOS Location Services locationServicesEnabled test passes when they are disabled in viewDidLoad and yes, according to @albertamg suggestion, if

ElasticSearch — use distance from point to affect query relevance

僤鯓⒐⒋嵵緔 提交于 2019-12-03 07:19:36
Trying to use ElasticSearch to create a search that uses distance from a centerpoint to influence relevance. I don't want to simply sort on distance from a point, which I know is possible, because I want relevance based on the searched query to also affect results. I'd like to pass in a search string, say "coffee", and a lat/lon, say "38, -77", and get my results ordered by a combination of how related they are to "coffee" and how close they are to "38, -77". Thanks! You can use distance function in the script of the Custom Score Query to modify _score based on the distance from a centerpoint.

Xcode Scheme Default Location is ignored in Tests

ぐ巨炮叔叔 提交于 2019-12-03 06:59:54
I've created a GPX file and added it to my project. If I have my project running, I can select the GPX file from the dropdown of possible locations to simulate and have it correctly apply the defined path. The project contains 2 schemes: the Main Scheme and the MainTest Scheme. I've set up both to use the GPX file as the "Default Location" on the "Options" tab. Further, Under the "Test" area of both schemes, I've specified the same file again. Main Scheme Run Options Main Scheme Test setup Test Scheme Run Options Test Scheme Test setup When I Run the app on a simulator, it correctly applies

Working with the Google Location API

谁说我不能喝 提交于 2019-12-03 06:53:39
Forgive me for my ignorance, but after several hours of searching, I'm having little luck. Anyway, I am attempting to write a small desktop application that will allow a user to enter an address and then have their approximate location returned in GPS coordinates. From what I can tell, Google provides a geocoding API[1] that allows requests in the following form: http://maps.googleapis.com/maps/api/geocode/output?parameters While I'm familiar with writing basic C Sharp applications, I really have no idea where to start when it comes to interfacing with this API. Any help that you guys could

A rails app which gets users location using HTML5 geolocation and saves to data base

半世苍凉 提交于 2019-12-03 06:25:46
问题 Seems pretty simple but I'm struggling. Here's what I have so far in the view. I display the location coords just to test its working. But I also want to persist on Database, hence the ajax call. Am I doing this the right way or is there an easier or better way? <p id="demo">Click the button to get your coordinates:</p> <button onclick="getLocation()">Try It</button> <script> var x=document.getElementById("demo"); var lat; var long; function getLocation() { if (navigator.geolocation) {

Worldwide location (country, region, city) select plugin for Rails, jQuery or Google Maps API?

好久不见. 提交于 2019-12-03 06:23:53
Is there any plugin which will help to create a dropdown menus for countries, regions and cities? At first user chooses country, then he has his region dropdown menu updated according to which country he has chosen, he chooses region and after that from 3rd menu a city. Plugin can be either for Ruby on Rails, jQuery or maybe javascript solution through google maps api? The Freebase Suggest jQuery plug-in provides pretty slick auto-complete functionality that provides suggestions in a drop-down, complete with Freebase/Wiki-style context info on mouseover. You can limit their suggestions to

PHP/MySQL: Select locations close to a given location from DB

情到浓时终转凉″ 提交于 2019-12-03 06:19:17
问题 In PHP, I have the following code for calculating the distance between two locations: <?php function distance($lat1, $long1, $lat2, $long2) { // DEGREE TO RADIAN $latitude1 = $lat1/180*pi(); $longitude1 = $long1/180*pi(); $latitude2 = $lat2/180*pi(); $longitude2 = $long2/180*pi(); // FORMULA: e = ARCCOS ( SIN(Latitude1) * SIN(Latitude2) + COS(Latitude1) * COS(Latitude2) * COS(Longitude2-Longitude1) ) * EARTH_RADIUS $distance = acos(sin($latitude1)*sin($latitude2)+cos($latitude1)*cos(

Country/State/City Database? [duplicate]

感情迁移 提交于 2019-12-03 06:10:02
问题 This question already has answers here : Closed 6 years ago . Possible Duplicate: Database of Countries and their Cities Ok, this one is a non technical question. I am creating a business directory and I'd like to categorize listings by location. Instead of giving users an option to enter the location, I am going to provide them with a list of locations which follow a Country/State/City format. I tried GeoWorldMap by GeoBytes. It looked promising in the beginning and I felt that is exactly