Follow along with the video below to see how to install our site as a web app on your home screen.
Anmerkung: This feature currently requires accessing the site using the built-in Safari browser.
<?php
$FileOnTheWebsite = "http://www.google.de/index.html";
$FileHandle = fopen($FileOnTheWebsite, "r");
if (!$FileHandle)
{
// Datei existiert nicht oder Internetseite ist "offline"
}
else
{
// Datei existiert bzw. Internetseite "online"
}
?>
<?php
function WebsiteAvailable($WebsiteURL)
{
$FileHandle = @fopen($WebsiteURL, "r");
if ($FileHandle)
{
fclose($FileHandle);
return true;
}
else
{
# No fclose() because the handle is already FALSE
return false;
}
}
// Beispiele
var_dump(WebsiteAvailable("http://www.google.de")); // TRUE
var_dump(WebsiteAvailable("http://www.example.invalid")); // FALSE
?>