geolocation

Phonegap with Compass and GPS coordinates

倖福魔咒の 提交于 2019-12-03 06:06:35
问题 I am working on a project that takes the compass script from Phonegap and i would like to connect it to my currect GPS position and than point to a fixed GPS position (like a restaurant etc.) Basicly the arrow must be pointing in the direction of the restaurant so i know which way to go/walk. These are the two i would like to combine: http://docs.phonegap.com/en/2.0.0/cordova_geolocation_geolocation.md.html#Geolocation http://docs.phonegap.com/en/2.0.0/cordova_compass_compass.md.html#Compass

Got an error when trying to get the geolocation in safari on iOS 10

半世苍凉 提交于 2019-12-03 06:05:06
[blocked] Access to geolocation was blocked over insecure connection to http://www.hnsjb.cn . Should I change my website to the https protocol? iOS 10 and also desktop Safari 10 seem to require https connection now. Safari also seems to be more strict than what Chrome did earlier. No mixed content warnings are allowed, Chrome allows e.g. map tiles to load over normal http. I could not find any guideline specific to Safari, but this issue has been discussed by other web browsers as well. In particular, the announcement about Google Chrome blocking geolocation over an insecure connection,

Find nearby users of an app (iPhone and Android)

情到浓时终转凉″ 提交于 2019-12-03 05:51:16
问题 I am working on an app that has an iPhone version as well as an Android version. My goal is... display a list of nearby users of my app (iPhone app users and Android app users). Lets say a list users which are currently within 1 mile or 2 miles radius and are currently using my app. This list will display on both apps, iPhone app and Android app. App will update the list when user clicks a Refresh button. My question is... What is the best way to accomplish above stated goal? Do I need to

Phonegap/Cordova geolocation not working on Android

落爺英雄遲暮 提交于 2019-12-03 05:47:04
问题 I'm having a trouble to get Geolocation working on Android in both emulator (even when I geo fix over telnet) and on device. Works on iOS, WP8 and in the browser. When I ask device for location using the following code, I always get an error (in my case custom Retrieving your position failed for unknown reason. with null both error code and error message). Related code: successHandler = (position) -> resolve App.Location.create lat: position.coords.latitude lng: position.coords.longitude

Fused Location Provider not getting location unless GPS is on

拟墨画扇 提交于 2019-12-03 05:39:03
So I have implemented the new Fused Location Provider API to get a location of the user but for some reason, I cannot get any location unless the GPS is on. Not always, will users have their GPS on and I would like to not have to ask them to turn their GPS on every time the load the app. How can I tell the API to give me a location with whatever provider it has available? Here is my code: public class FusedLocationService implements LocationListener, GoogleApiClient.ConnectionCallbacks, GoogleApiClient.OnConnectionFailedListener { public interface OnLocationChangedListener { public void

What does map.setMyLocationEnabled(true) really do

本秂侑毒 提交于 2019-12-03 05:31:21
I am setting: map.setMyLocationEnabled(true) But I am wondering what this really does. What I know: I get a locate me button in the upper right corner of the map I get a blue icon on the map that represents my current location Here is my concern. I am writing a location aware app but I am concerned about battery. Elsewhere in my app (via preferences) I set up a LocationManager and listen for location events so I can log them. But part of my preferences is the accuracy at which I get updates and the interval. When I turn off my LocationManager: locationManange.removeUpdates(LocationListener

Calculating distance within a building

為{幸葍}努か 提交于 2019-12-03 05:19:51
问题 I started doing some thinking about creating an Android application that can be used within a corporate building to determine what room you are in. Obviously I'm thinking GPS and network locations wouldn't be accurate enough to accomplish this. (Not to mention the instability of GPS signal inside) I looked briefly into calculating distance via the accelerometer, but it is apparently highly volatile and leaves a large margin for error. I've also considered some sort of triangulation from

How to convert postcode to Geolocation (latitude & longitude) using google maps api?

不问归期 提交于 2019-12-03 05:11:29
问题 I just want to get latitude & longitude using the post code with Google maps API. I am using PHP for development. How can I do this? The post code can be from any where in this world. 回答1: You can do this using google map Geocoding API. Please find below example, but to correct latitude/longitude and address you need to pass full address along with zipcode. For more detail please click on below link: http://code.google.com/apis/maps/documentation/geocoding/ <?php $url ="http://maps.googleapis

Intent for Google Maps 7.0.0 with location

我是研究僧i 提交于 2019-12-03 05:09:28
问题 At first I know that there are several similar questions on StackOverflow. Curriently I use the geo scheme for addressing points which can be handled by other apps. Like in the example of the Android documentation (by the way it seems to be outdated the RFC it out!) I tried to use something like this: geo:50.95144,6.98725?q=50.95144,6.98725%20(Disneyland) So I get a intent chooser where I can select an App which showed me in case of Google Maps Disneyland with a marker on it. Now it seems

How web apps ask location of mobile device?

本秂侑毒 提交于 2019-12-03 05:06:34
问题 Many modern mobile phones (google nexus one etc.) have some kind of built in location service. when i go to a some website (eg. google.com) that website asks if I'm willing to share my location with that site. How do you actually ask for mobile device to give out it's location to the site? And in what format is that location given? I've got no clue and didn't find any answers from google, neither. 回答1: Web applications on iPhone, Android or even certain desktop browsers (some recent versions