Wallogit.com
2017 © Pedro Peláez
PHP Class for fping command
PHP Class for fping command, (*1)
Requires: fping, (*2)
For RedHat/CentOS 6, 7, (*3)
[root@centos ~]# yum install epel-release [root@centos ~]# yum install fping
$ composer require nelisys/ping
Example php file., (*4)
// test-ping.php
require 'vendor/autoload.php';
use Nelisys\Ping;
$host = new Ping('127.0.0.1');
var_dump($host->ping());
Test run php file., (*5)
$ php test-ping.php
Array
(
[127.0.0.1] => 0.14
)