How do i send a notification/message/alert from php server to my android app. I don't want to use C2DM service. Is there any alternative ? Thanks in advance
4 Answers
There's another option (for push): MQTT protocol

- 53,191
- 11
- 86
- 129
-
and now I see that it was already discussed here: http://stackoverflow.com/questions/1243066/does-android-support-near-real-time-push-notification – Nir Alfasi Feb 29 '12 at 08:25
You can check the Urban airship http://urbanairship.com/ as well there many other paid services to send push notification in android apps.

- 717
- 1
- 6
- 18
There are free publish subscription models. You may try the google cloud messaging service service http://developer.android.com/google/gcm/index.html .
Alternatively you may setup an xmpp server and use its pubsub extension .

- 1,029
- 9
- 15
There are only two alternatives of C2DM as below
Polling. The application itself would periodically poll your servers to check for new messages. You would need to implement everything from queing messages to writing the polling code. Alerts are no good if they’re delayed due to a low polling period but the more frequently you poll, the more the battery is going to die.
SMS. Android can intercept SMS messages and you could include a payload to tell the app what to do. But then why not just use SMS in the first place?

- 6,098
- 5
- 36
- 55