简体   繁体   English

parse.com:从我自己的CMS发送推送通知

[英]parse.com : send push notification from my own CMS

I want to use the Parse.com api to send push notifications but I need to send these push notifications from my CMS in PHP ...and not from Dashboard from parse.com. 我想使用Parse.com api发送推送通知,但是我需要从PHP中的CMS发送这些推送通知,而不是从parse.com的仪表板发送。 Its possible to integrate my CMS with parse`s dashboard? 是否可以将我的CMS与parse`s仪表板集成? I have tried search in parse's doc but haven't found 我曾尝试在parse的文档中进行搜索,但未找到

here is the panel form 这是面板表格

</div>
    <div class="section_body">
        <div id="push_errors" style="display: block;">Your message cannot be empty</div>
        <div class="ui_action_button disabled" id="send_push"><span>Send now</span><i class="icon_send"></i></div>
    </div>
</div>

https://parse.com/docs/push_guide#installations/PHP https://parse.com/docs/push_guide#installations/PHP

$data = array("alert" => "Hi!");

ParsePush::send(array(
  "channels" => ["PHPFans"],
  "data" => $data
));

or: 要么:

$query = ParseInstallation::query();
$query->equalTo("design", "rad");
ParsePush::send(array(
  "where" => $query,
  "data" => $data
));

I think it is possible. 我认为有可能。 Have a look at their docs here: https://parse.com/docs/push_guide#sending/PHP 在这里看看他们的文档: https : //parse.com/docs/push_guide#sending/PHP

For example (copied from docs): 例如(从文档复制):

"With the PHP SDK, the following code can be used to alert all subscribers of the "Giants" and "Mets" channels about the results of the game. This will display a notification center alert to iOS users and a system tray notification to Android users." “使用PHP SDK,以下代码可用于向“巨人”和“大都会”频道的所有订阅者提醒游戏结果。这将向iOS用户显示通知中心警报,并向Android显示系统任务栏通知用户。”

$data = array("alert" => "Hi!");

ParsePush::send(array(
  "channels" => ["PHPFans"],
  "data" => $data
))

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM