我如何构建和跟踪用户位置的 iPhone 应用程序上传坐标
我正在为 iPhone 编写一个应用程序,以便沿着我的网站跟踪用户的位置。谁能给我任何关于从哪里开始的指示。我非常擅长 mysql 和 php 等,但我是 iphone 应用程序的新手。
应用程序中的坐标需要能够上传到我设置的 api。
谢谢
I am writing an app for iphone to go along site my website which tracks the location of the user. Can anyone give me any pointers on where to begin. I am very good with mysql and php etc but I am a novice with iphone apps.
The coordinates from the app need to be able to upload to my api which I have set up.
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您可能想要做的是创建一个可以在后台运行的简单应用程序。
http://developer.apple.com/ Library/ios/#documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/BackgroundExecution/BackgroundExecution.html
在后台执行期间,您无法对网络做太多事情,因此我建议使用 CoreData 和然后在恢复/启动时将 HTTP post 发送到 PHP 页面并将其记录到数据库中?
What you probably want to do is create a simple app that can run in the background.
http://developer.apple.com/library/ios/#documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/BackgroundExecution/BackgroundExecution.html
During background execution you cannot do anything really too much with the network so I suggest logging it using CoreData and then on resume/startup to send an HTTP post to a PHP page that logs it into your DB?
您可能需要查看 HTML5 地理定位 API。另建议阅读“使用 HTML、CSS 和 JavaScript 构建 iPhone 应用程序”。我在 Android 上阅读了同一本书,非常高兴。使用 HTML5/CSS/JS 构建您的应用程序也意味着它可能可以在其他平台上运行。
You might want to check out the HTML5 geolocation API. Also reading "Building iPhone Apps with HTML, CSS, and JavaScript" is recommended. I read the same book for Android and was very pleased. Building your app in HTML5/CSS/JS will also mean that it will probably work on other platforms.