PHP code example of randomhost / icinga-notification
1. Go to this page and download the library: Download randomhost/icinga-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/ */
randomhost / icinga-notification example snippets
namespace randomhost\Icinga\Notification;
ent;
$nmaClient = new NmaClient();
$notification = new NotifyMyAndroid($nmaClient);
$notification->setOptions(
getopt(
$notification->getShortOptions(),
$notification->getLongOptions()
)
);
$notification->run();
echo $notification->getMessage();
exit($notification->getCode());