Php Firebase通知给了我;“成功”;但我不知道';无法在IOS上获得通知
我在安卓系统上收到通知,但当我将通知发送到IOS设备时,却没有收到通知,即使它显示成功 我添加了徽章、声音、振动、优先级。。等等,但这些都没有解决问题Php Firebase通知给了我;“成功”;但我不知道';无法在IOS上获得通知,php,firebase,codeigniter,push-notification,firebase-cloud-messaging,Php,Firebase,Codeigniter,Push Notification,Firebase Cloud Messaging,我在安卓系统上收到通知,但当我将通知发送到IOS设备时,却没有收到通知,即使它显示成功 我添加了徽章、声音、振动、优先级。。等等,但这些都没有解决问题 function sendNotification($title, $body, $aid,$destination) { $url = 'https://fcm.googleapis.com/fcm/send'; $message = array( 'title' => $title, '
function sendNotification($title, $body, $aid,$destination)
{
$url = 'https://fcm.googleapis.com/fcm/send';
$message = array(
'title' => $title,
'body' => strip_tags($body),
'vibrate' => 1,
'sound' => 1,
"action" => "url",
'sound' => 'default',
'badge' => '1',
'priority'=>'high',
"action_destination" => $destination,
);
$fields = array(
'registration_ids' => $aid,
'data' => $message
);
$headers = array(
'Authorization: key=KEYHERE',
'Content-Type: application/json'
);
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($fields));
$result = curl_exec($ch);
curl_close($ch);
}
移动开发者说有一个新的firebase更新,坦率地说,我认为他正在。。。有人能给我解释一下发生了什么事吗?我想我在这里的角色已经完成了,但你们可能会发现我的代码有问题