As the title says, I want to send a push-notification to my android phone via a form on my website. I've googled but didn't found the right answer to my question.
Maybe someone can give me an idea to do that or what I need for that.
You can use Parse javascript(JS) API to trigger the push notification from cloud. In other words, you can write a cloud function that queries the Installation table and sends push notification. This cloud can be triggered via Parse JS API. Another way, you can use third party of Parse API extension like Parse4j. You can implement your web site server side in java and via Parse4j you can trigger cloud function when the form is submitted and controlled. Hope this helps.
Regards.
Related
I know how to implement GCM in my App but I don't know how to build a server able to send notification to ALL the users.
I need something quite simple (just sending notification), could you advise me any services and tutorial in order to set up the server?
I wish something not to complex, because everything that I will need from my app is receiving whether simply notifications to display or to tell the app that some new data is available for downloading.
Thank you!!
Prerequisite for GCM Application
Google API Server Key
GCM RegId of the Android Device to communicate via GCM
If you get clear concept about GCM, please visit here
If you want to use java for server side then visit my answer.
Related Links:
Android Push Notifications using Google Cloud Messaging (GCM), PHP and MySQL
Android Warriors
If you're using PHP, you could use this approach to send GCM message to your client refer this
You could setup your own local server on PHP using AMPP. refer this
Probably, the simplest way is to add a cloud endpoint module refer this. Then, write a simple service refer this that sends the messages. Finally, let Android Studio deploy it.
I want to implement notification of news or article in Android.User can put the new article or news on the server after that i want to show notification in my app through PHP MySql.Can someone help me how to do this.Thanks to appreciate.
PHP is a server side process - it only runs when a user/app/service requests the page.
MySQL is a server based database. It's not "connected" to your app.
Your app must then "poll" your website (it has to request data from it periodically). This is best done using an XMPP type service. You can find a lot of info on XMPP - basically, it's complicated to setup and run. It probably isn't worth doing unless you've already done it.
Alternatively, you can use an existing XMPP service. Google Cloud Messaging (GCM) is an excellent option for most Android devices (any that has Google Play installed... so, it won't work on an Amazon Fire phone, for example). It's not "easy" to setup, but they do a lot of really hard stuff for you. Also, there are a lot of references for setting it up, like this from Google:
https://developer.android.com/google/gcm/client.html
You can use Google cloud messaging to display Notification or You need to create a service that always ping your server for new message.
please try 1st options its better.(2nd options is worst because it use more battery & internet data )
You can use google cloude messaging service to send notificaion in device so please register your application on google service all step are cover below link.
Open below link and follow step
http://www.androidhive.info/2012/10/android-push-notifications-using-google-cloud-messaging-gcm-php-and-mysql/
You can use GCM (Push notification) and implement the notification generated method inside onMessage method.
For reference use this linkAndroid Push Notifications using Google Cloud Messaging (GCM), PHP and MySQL
What you are looking is Google cloud messaging.
For Gcm you have to write a server in your case is php server.
For Gcm server code or for testing purpose refer this link.
Android: Test Push Notification online (Google Cloud Messaging)
But firstly it is best to learn about GCM itself and it's mechanism.
For this you can refer this link.
https://developer.android.com/google/gcm/index.html
You have to do some settings in Google console which are all explained in this article including the android side code.
Hop i helped you.
I am a newbie in android. I have developed few applications, but all are plain and simple, just used the built in features of android.
I was asked about push notifications, in one of my interviews and I decided to have a look at what Push Notifications are. I understand the concept of Push Notifications(I think), but whenever I read the term "Server", it's freaking me out.
I understand all the client side coding, but I don't get how to implement the server side coding. I have seen some people use XMPP, MQTT, etc., What are those? Here is my scenario and what I want to know..
Scenario ::: Let's say I have a website, with a table (the values are retrieved from database), where I update a few columns every day. I want these updates to be reflected in my android application. So, as I have read, push notifications can tell the application that there are updates available. Good. I am fine till here..
When the application gets the notification, should my application, contact the website and get the latest information? or will the updated information sent through Push Notification? I guess, my application would be contacting the website and get the information. Now, how do I get the data from the website? Should I get the source of the page and do some kind of parsing or something?
I will be asking more questions, as the experts clear my questions...
Sorry, if my questions are too naive, but this is the only place that can help me...
Push Notifications means Google Cloud Messaging for Android (GCM) is a service that allows you to send data from your server to your users' Android-powered device.
You can refer to this documentation
Google Cloud Messaging for Android
GCM: Getting Started
And there is also Demo App Tutorial given
in your case you need to create HTTP web service for getting data from the server.so when you get notification about update on server side.you just need to call this web service and get the data you need to update
I am currently working on an android app for a client and it needs to use push notifications from parse.com. I have been able to send notifications from the emulator and also receive messages from the server when someone sends a message from there but I want to do it in such a way such that the server automatically sends me a notification depending on a condition. Is it possible and if yes, could someone direct as to how to do it.
Your client would need to notice the condition and send the message.
What event did you trigger a notification from?
Yoou can use Parse Cloud Code. If you have your XML parsing code in a 3rd party server, make an external call to the 3d party server through REST from Parse Cloud Code. Inside your Parse Cloud Code you can check the date attribute changes, and if your condition is met, you can send push notification from the Parse Cloud Code. So your android application should communicate only with the Parse Cloud Code and let the cloud code talk to your 3rd party server.
I am getting data from the server, and I want to show a push notification in android. How can I do this?
Be clear to yourself What do you exactly want, I think you are using just a web service to get data. For push Notifiaction you need to implement Android Cloud to Device Messaging and here you can find complete tutorial.
Cheers