PHP code example of wiebenieuwenhuis / expo-notification
1. Go to this page and download the library: Download wiebenieuwenhuis/expo-notification library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
wiebenieuwenhuis / expo-notification example snippets
$notification = new ExpoNotification();
$result = $notification
->to([
'ExponentPushToken[GoVJ_qPG41_nHi-4EQS5UU]',
'ExponentPushToken[P7yjE4MojbyaqpOiwwANgB]'
])
->title('test')
->body('message')
->data([
'row' => 'item'
])
->badge(1)
->channel('default')
->sound('default')
//->silent()
//->test()
->send();
print_r($result);