https://www.r10.net/php/2121096-ones...derim-php.html
İhtiyacı olanlar buradan ulaşabilir.
ONESIGNAL BOT Yazdırılacak.
7
●209
- 31-08-2019, 01:06:26Üyeliği durdurulduFirebase, onesignale bağlıyor zaten hocam.Kei adlı üyeden alıntı: mesajı görüntüle
- 31-08-2019, 14:46:03Ö.M detaylı olarak dönüş sağladım. Lakin forum içerisinde benzer bir mesajın gönderilmesi için yazılmış basit bir php kodu mevcut.
Cankat adlı üyeden alıntı: mesajı görüntüle - 31-08-2019, 14:48:09Üyeliği durduruldu1 saate pcye geçiyorum. Kendi kodumu atacağım buraya basit kullanım
Php kodu:
function sendMessage($mesaj){ $content = array( "en" => $mesaj ); $fields = array( 'app_id' => "$APP IDIYI BURAYA GİR", 'included_segments' => array('All'), 'data' => array("foo" => "bar"), 'contents' => $content ); $fields = json_encode($fields); print("nJSON sent:n"); print($fields); $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, "https://onesignal.com/api/v1/notifications"); curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json; charset=utf-8', 'Authorization: Basic API KEYİ BURAYA GİR')); curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE); curl_setopt($ch, CURLOPT_HEADER, FALSE); curl_setopt($ch, CURLOPT_POST, TRUE); curl_setopt($ch, CURLOPT_POSTFIELDS, $fields); curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE); $response = curl_exec($ch); curl_close($ch); return $response; } - 31-08-2019, 15:16:10Üyeliği durdurulduÇok Teşekkürler.halilx35 adlı üyeden alıntı: mesajı görüntüle
- 31-08-2019, 17:07:06Üyeliği durduruldu