1
0
Fork 0
mirror of https://github.com/binwiederhier/ntfy.git synced 2024-12-24 02:32:48 +01:00
ntfy/examples/subscribe-php/subscribe.php
2021-12-03 20:38:21 -05:00

12 lines
205 B
PHP

<?php
$fp = fopen('https://ntfy.sh/phil_alerts/json', 'r');
if (!$fp) {
die('cannot open stream');
}
while (!feof($fp)) {
$buffer = fgets($fp, 2048);
echo $buffer;
flush();
}
fclose($fp);