Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
Identical to file(), except that file_get_contents() returns the file in a string. On failure, file_get_contents() will return FALSE
<?php
if ($fp = @fsockopen($host, 80, $errno, $errstr, 10))
{
echo "Website is online!";
fclose($fp);
}
else
{
echo "Website is offline!";
}
?>