简体   繁体   English

如何将通知从Android手机发送到网站?

[英]How to send notifications from an Android Phone to a website?

I am currently working on my project like Parental control. 我目前正在从事像“家长控制”这样的项目。 I am trying to find a way , that if there is any procedure or way to send a notification from an android phone to a website whenever the android phone sends/receives an SMS and dials/receives a call. 我正在尝试找到一种方法,即每当Android手机发送/接收短信并拨打/接听电话时,是否有任何程序或方法将通知从Android手机发送到网站。 On website , a database will be maintained for these notifications. 在网站上,将为这些通知维护数据库。

I think you want to maintain database, based on mobile even. 我认为您甚至想维护基于移动设备的数据库。 You can create API call, that will send data to database while any activity happened on mobile. 您可以创建API调用,该调用将在移动设备上发生任何活动时将数据发送到数据库。 That api will store notification on DB. 该api将在DB上存储通知。

On web you can create AJAX call that will check in DB, if any new notification come or not, if new record found you can show it on website. 在网络上,您可以创建AJAX呼叫,该呼叫将在数据库中签入,无论是否有新通知,如果发现新记录,您都可以在网站上显示它。

This is what I think the best way to do so... 我认为这是最好的方法...

You could send a get request or post request to a website. 您可以向网站发送获取请求或发布请求。
Sending POST data in Android 在Android中发送POST数据
Android - Sending HTTPS Get Request Android-发送HTTPS获取请求

Just some examples. 只是一些例子。 You will probably be looking for a restful api. 您可能正在寻找一个宁静的api。 I haven't read this, but it looks viable: 我还没看过,但是看起来可行:
http://www.9lessons.info/2012/05/create-restful-services-api-in-php.html http://www.9lessons.info/2012/05/create-restful-services-api-in-php.html

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何在Android中安排通知并在固定时间发送 - How to schedule notifications in android and send at fixed time 如何将表格信息从网站发送到电话号码的邮件收件箱? - How to send form information from website to a phone number's message inbox? 如何从网站聊天发送Android推送通知 - How to send android push notification from website chat 如何在React-Native中从php向Android Mobile发送推送通知? - How to send push notifications to android mobile from php in react-native? 如何将通知从 php 服务器端发送到 Visual Basic 客户端,如 android - How to send notifications from php server side to Visual Basic client side like android 如何从其他网站向Facebook Android应用发送通知? 它显示在网站上。 但不在应用程式上 - How to send notification from other website to facebook android app? It shows on the website. But not on the app 将数据从android Studio发送到网站(php) - Send Data from android Studio to a website(php) 从PHP服务器向Android设备发送推送通知 - Send Push Notifications from PHP Server to Android Devices 通过 Firebase 从 Laravel 服务器向 Android 应用程序发送推送通知 - Send Push Notifications from Laravel Server to Android App via Firebase 如何使用FCM从php向iOS发送推送通知 - how to send push notifications from php to IOS using FCM
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM