com php-src: PR #260: Update css for 404 pages to feel more up to date and have a consistent layout across browsers: sapi/cli/php_cli_ server.c
sapi/cli/tests/php_cli_server_013.ph pt sapi/cli/tests/php_cli_server_014.phpt

From: Date: Mon, 14 Jan 2013 19:43:14 +0000
Subject: com php-src: PR #260: Update css for 404 pages to feel more up to date and have a consistent layout across browsers: sapi/cli/php_cli_ server.c
sapi/cli/tests/php_cli_server_013.ph pt sapi/cli/tests/php_cli_server_014.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-70944@lists.php.net to get a copy of this message
Commit: 785e66adb536d40a26e4813e6b4ad96b2fdbef43 Author: Lars Strojny <lstrojny@php.net> Mon, 14 Jan 2013 20:43:14 +0100 Parents: 97157b376f4cd484fddfa0f71aba719037c1d615 Branches: PHP-5.5 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=785e66adb536d40a26e4813e6b4ad96b2fdbef43 Log: PR #260: Update css for 404 pages to feel more up to date and have a consistent layout across browsers Bugs: https://bugs.php.net/260 Changed paths: M sapi/cli/php_cli_server.c M sapi/cli/tests/php_cli_server_013.phpt M sapi/cli/tests/php_cli_server_014.phpt Diff: diff --git a/sapi/cli/php_cli_server..c b/sapi/cli/php_cli_server.c index 74d2ad2..700a495 100644 --- a/sapi/cli/php_cli_server.c +++ b/sapi/cli/php_cli_server.c @@ -246,7 +246,7 @@ static php_cli_server_http_reponse_status_code_pair status_map[] = { static php_cli_server_http_reponse_status_code_pair template_map[] = { { 400, "<h1>%s</h1><p>Your browser sent a request that this server could not understand.</p>" }, - { 404, "<h1>%s</h1><p>The requested resource %s was not found on this server.</p>" }, + { 404, "<h1>%s</h1><p>The requested resource <code class=\"url\">%s</code> was not found on this server.</p>" }, { 500, "<h1>%s</h1><p>The server is temporarily unavailable.</p>" }, { 501, "<h1>%s</h1><p>Request method not supported.</p>" } }; @@ -283,8 +283,10 @@ ZEND_DECLARE_MODULE_GLOBALS(cli_server); * copied from ext/standard/info.c */ static const char php_cli_server_css[] = "<style>\n" \ - "body { background-color: #ffffff; color: #000000; }\n" \ - "h1 { font-family: sans-serif; font-size: 150%; background-color: #9999cc; font-weight: bold; color: #000000; margin-top: 0;}\n" \ + "body { background-color: #fcfcfc; color: #333333; margin: 0; padding:0; }\n" \ + "h1 { font-size: 1.5em; font-weight: normal; background-color: #9999cc; min-height:2em; line-height:2em; border-bottom: 1px inset black; margin: 0; }\n" \ + "h1, p { padding-left: 10px; }\n" \ + "code.url { background-color: #eeeeee; font-family:monospace; padding:0 2px;}\n" \ "</style>\n"; /* }}} */ diff --git a/sapi/cli/tests/php_cli_server_013.phpt b/sapi/cli/tests/php_cli_server_013.phpt index 570798a..0e3f4ff 100644 --- a/sapi/cli/tests/php_cli_server_013.phpt +++ b/sapi/cli/tests/php_cli_server_013.phpt @@ -88,7 +88,7 @@ Content-Type: text/html; charset=UTF-8 Content-Length: %d <!doctype html><html><head><title>404 Not Found</title><style>AAA</style> -</head><body><h1>Not Found</h1><p>The requested resource / was not found on this server.</p></body></html> +</head><body><h1>Not Found</h1><p>The requested resource <code class="url">/</code> was not found on this server.</p></body></html> HTTP/1.1 404 Not Found Host: %s Connection: close @@ -96,7 +96,7 @@ Content-Type: text/html; charset=UTF-8 Content-Length: %d <!doctype html><html><head><title>404 Not Found</title><style>AAA</style> -</head><body><h1>Not Found</h1><p>The requested resource /main/style.css was not found on this server.</p></body></html> +</head><body><h1>Not Found</h1><p>The requested resource <code class="url">/main/style.css</code> was not found on this server.</p></body></html> HTTP/1.1 404 Not Found Host: %s Connection: close @@ -104,5 +104,5 @@ Content-Type: text/html; charset=UTF-8 Content-Length: %d <!doctype html><html><head><title>404 Not Found</title><style>AAA</style> -</head><body><h1>Not Found</h1><p>The requested resource /main/foo/bar was not found on this server.</p></body></html> +</head><body><h1>Not Found</h1><p>The requested resource <code class="url">/main/foo/bar</code> was not found on this server.</p></body></html> diff --git a/sapi/cli/tests/php_cli_server_014.phpt b/sapi/cli/tests/php_cli_server_014.phpt index f8a9905..e8bb5fa 100644 --- a/sapi/cli/tests/php_cli_server_014.phpt +++ b/sapi/cli/tests/php_cli_server_014.phpt @@ -77,4 +77,4 @@ Content-Type: %s Content-Length: %d <!doctype html><html><head><title>404 Not Found</title><style>AAA</style> -</head><body><h1>Not Found</h1><p>The requested resource /main/no-exists.php was not found on this server.</p></body></html> +</head><body><h1>Not Found</h1><p>The requested resource <code class="url">/main/no-exists.php</code> was not found on this server.</p></body></html>

« previous php.cvs (#70944) next »