Skip to content

Instantly share code, notes, and snippets.

@maxkostinevich
Created December 26, 2015 19:19
Show Gist options
  • Save maxkostinevich/bab3af7fd21387a7f0d5 to your computer and use it in GitHub Desktop.
Save maxkostinevich/bab3af7fd21387a7f0d5 to your computer and use it in GitHub Desktop.
SEO-Friendly Maintenance Mode
<?php
$protocol = "HTTP/1.0";
if ( "HTTP/1.1" == $_SERVER["SERVER_PROTOCOL"] )
$protocol = "HTTP/1.1";
header( "$protocol 503 Service Unavailable", true, 503 );
header( "Retry-After: Mon, 28 Dec 2015 12:00:00 GMT" );
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>WEBSITE TITLE</title>
</head>
<body>
<h1 style="margin-top:20px;text-align:center;">Temporarily Down for Maintenance</h1>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment