tylercd100/server-status

1.1.0 2016-04-16 21:48 UTC

This package is auto-updated.

Last update: 2024-03-12 08:50:01 UTC


README

Latest Version Software License Build Status Scrutinizer Code Quality Code Coverage Dependency Status Total Downloads

Can ping and return status code of a host

Installation

Install via composer - In the terminal:

composer require tylercd100/server-status

Usage

use Tylercd100\ServerStatus\Host;

$host = new Host("google.com"); // or an IP address; 127.0.0.1

echo "Host ping: " . $host->ping() . "\n";
echo "Host status code: " . $host->status() . "\n";

# Host ping: 30.0
# Host status code: 200