I created a project on one signal.
I can send to php notification on my phone.
The problem comes when it arrives more than one notification. The new notification replaces the previous notification (not yet read ).
How do you get instead say that Android has 2 unread notifications?
The array can i send:
$fields = array(
'app_id' => "XXXXXXXXXXXXXXXXXXXXXX",
'included_segments' => array('All'),
'data' => array("foo" => "bar"),
'headings' => array("en" => "TEST"),
'contents' => $content,
'android_visibility' => '0',
'priority' => '10',
'android_group' => '',
'android_group_message' => array("en" => "$[notif_count] message"),
'url' => "http://www.google.it"
);
Thank you!
Use single quotes or escape $
here if you want to use $
as character
'android_group_message' => array("en" => "\$[notif_count] message"),
OR
'android_group_message' => array("en" => '$[notif_count] message'),
You can try to set value to 'android_group', like this:
'android_group' => 'sameGroup'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With