如何在android中使用C2DM实现推送通知?
我想在 android 中制作应用程序,其中我想向服务器发送一些消息,并且还希望在 android 中通过 C2DM 有任何更新时从服务器获取通知。
如何向第三方服务器发送消息。 (第三方服务器,如 php)并且需要输入才能将消息发送到第三方服务器。如何将响应第三方服务器发送到 C2DM 并从 C2DM 向 Android 设备获取通知?
I would like to make app in android in which i wand to send some message to server and also want to get notification from server if there is any updates via C2DM in android.
How to send message to the third party server. (Third-party server like php)and inputs are necessary to send message to the third-party server. and how to send response Third-party server to C2DM and get notification from C2DM to Android device?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这就像问“我如何编写 Android 应用程序?”并期望得到完整的答案。
我建议您从阅读以下内容开始:
http://code.google.com/intl/sv-SE /android/c2dm/index.html
然后下载 Chrome To Phone 源代码,看看他们如何实现 C2DM 解决方案。这相当复杂,但如果您知道如何从 Android 应用程序和服务器发出 http POST,您就会成功。
Well that's like asking "How do I write an Android application?" and expect to get a full answer.
I suggest you start with reading this:
http://code.google.com/intl/sv-SE/android/c2dm/index.html
Then download the Chrome To Phone source code see how they implement the C2DM solution. It is fairly complicated but if you know how to make http POSTs from your Android application and your server you will succeed.