geolocation

how to get the client/user location details

孤街醉人 提交于 2019-12-21 20:39:00
问题 In my application I want to track the client/user location to store in database. I'm using this code to get the user IP Address string VisitorsIPAddr = string.Empty; if (HttpContext.Current.Request.ServerVariables["HTTP_X_FORWARDED_FOR"] != null) { VisitorsIPAddr = HttpContext.Current.Request.ServerVariables["HTTP_X_FORWARDED_FOR"].ToString(); } else if (HttpContext.Current.Request.UserHostAddress.Length != 0) { VisitorsIPAddr = HttpContext.Current.Request.UserHostAddress; } ipAddress =

Windows Phone 7 Emulator Location Data Format

半腔热情 提交于 2019-12-21 17:55:12
问题 I am looking for a format of the location data used by the Windowws Phone Emulator Additional Tools. On the tab "Location" there is an option to save/open recorder data. I ask this question because I need simulate geo position change but Location Tab doesn't work for me. As a workaround I am going to create a file of the location data and open it in the emulator. 回答1: It's a simple XML file in this format: <?xml version="1.0" encoding="utf-8"?> <WindowsPhoneEmulator xmlns="http://schemas

Android Emulator having issues with Geolocation

ぐ巨炮叔叔 提交于 2019-12-21 17:06:03
问题 I have been using Android and the 2.2 emulator for a bit now and just started running into an issue. My geolocation is not being set in the Emulator. At first I thought it was an issue with PhoneGap 0.92 but after reverting to .91 and opening an older project the same holds true. In DDMS my coordinates are set and I 'send' them. I also telnet and issue the geo fix command and I get a OK response. It seems all is well but for some reason the emulator still has no clue. I found some older posts

How to calculate geography bounding box in iOS?

情到浓时终转凉″ 提交于 2019-12-21 12:59:46
问题 I'd like to make a Geographic Bounding box Calculation in iOS. It can be aprox. Input Parameters: Current Location (Example: 41.145495, −73.994901) Radius In Meters: (Example: 2000) Required Output: MinLong: (Example: 41.9995495) MinLat: (Example: −74.004901) MaxLong: (Example: 41.0005495) MaxLat: (Example: −73.004901) Requirement: No Network Call Any Ideas? Mapkit / CoreLocation does not seem to offer this type of thing? Any other Geographic SDK that i could use? Thanks 回答1: I think you can

Why is Geolocation in Mobile Safari way less accurate than the location in a native App?

陌路散爱 提交于 2019-12-21 12:32:04
问题 I'm using the Geolocation API (often referred to as "HTML5 Geolocation") to get the current position of the user. It is updated automatically if you move (checked every second). Primarily targeted (and currently tested) at iPhones, but should work on other mobile devices too. You can see an example here: http://jsbin.com/uyoyey/ The accuracy, which you can see in each line after the pipe, is around 3000 (meters) when I'm testing (outside). Which is quite bad obviously. The native Maps-App on

GPS icon is still blinking after locationManager.removeUpdates() and by setting locationManager to null

浪尽此生 提交于 2019-12-21 11:28:09
问题 I am developing the Location Tracking application. But i am stopping getting the location update by doing 2 things... locationManager.removeUpdates(this); and setting locationManager reference to null. This will stop getting location co-ordinates as i want... But the problem is the gps icon is still blinking.. which will draining the device's battery. So please help me in stopping this GPS fixes... 回答1: If you display your position and/or the compass in your mapView, you have to disable them.

HTML5 Geolocation from external GPS

試著忘記壹切 提交于 2019-12-21 11:01:11
问题 We have used HTML5s navigator.geolocation and found it to be very good on iOS and Android smartphones. Now the users want the same HTML5 web app to run on a laptop with external GPS. Using Windows 7 on the laptop I just can't figure a way to share the location to a HTML5 browser (tried Safari, FF, IE, Chrome). For testing I am using a GlobalStat BU-353 USB GPS which works standalone and I have found GPSDirect (cool freeware) to feed that signal to Win7 Sensor Location Services but still the

LocationRequest smallest displacement and accuracy

戏子无情 提交于 2019-12-21 09:00:28
问题 I'm building an Android app in which I need to have a very accurate location at a very high frequency. I dove into google play services api for location, and found the LocationRequest.setSmallestDisplacement very useful to limit battery consumption. However, as I am testing it indoor, the locations I get have an accuracy that varies a lot (sometimes 10m, sometimes 96m...), even when I set the Priority of my request as high accuracy. My prob1em is that setSmallestDisplacement doesn't give a sh

Initiating a Phonegap plugin after device restart

浪子不回头ぞ 提交于 2019-12-21 08:00:13
问题 I am in the process of developing a hybrid Phonegap app for Android. The app uses just the one plugin which I am developing as well. The plugin does three things Watches for geo-location changes (both foreground and background) Sets up a half-hourly alarm to perform certain periodic tasks Listens for push messages. I use the pushy.me service and the code I use follows their documentation. I had implemented the code to get the application to tune in to device reboots with some trepidation but

Google map's marker not center after resize on bootstrap tab

一个人想着一个人 提交于 2019-12-21 06:59:59
问题 I bought a geolocation map script and when applied to bootstrap tab it will only shown small top left span. I added resize to overcome it. $(document).ready(function() { $(‘a[href=”#tab2”]’).click(function(e) { setTimeout(initialise, 1000); }); </script> function initialise() { var myMap = document.getElementById('map-myid1'); google.maps.event.trigger(myMap, 'resize'); }; }); The problem I am facing is the marker of map not center, it will hide left outside of map. How to fix it? See in real