0
我想通過對象ID向特定設備發送解析通知。解析:將通知推送到特定設備
從PHP API調用是:
<?php
$url = 'https://api.parse.com/1/push';
$appId = //app id
$restKey = // rest key
$target_device = 'TARGET_INSTALLATION_OBJECT_ID_HERE'; // using object Id of target Installation.
$push_payload = json_encode(array(
"where" => array(
"objectId" => $target_device,
),
"data" => array(
"alert" => "This is the alert text."
)
));
// curl exec...
我怎麼能由JavaScript獲得TARGET_INSTALLATION_OBJECT_ID_HERE(因爲我使用PhoneGap的)?
感謝