diff --git a/CHANGES b/CHANGES index acee695735..821aff66d7 100644 --- a/CHANGES +++ b/CHANGES @@ -1,6 +1,9 @@ -*- coding: utf-8 -*- Changes with Apache 2.5.1 + *) Update DOCTYPE tags in server-generated HTML. PR62989. + [Andra Farkas , Giovanni Bechis ] + *) mod_setenvif: Passing an env-variable parameter of "--early" in non-perdir context runs directives from this module before `RequestHeader ... early` are evaluated. This allows results of SetEnvIf conditionals to be used diff --git a/docs/docroot/index.html b/docs/docroot/index.html index f5f1c377b6..a4e4d11f56 100644 --- a/docs/docroot/index.html +++ b/docs/docroot/index.html @@ -1 +1,9 @@ -

It works!

+ + + +It works! Apache httpd + + +

It works!

+ + diff --git a/include/httpd.h b/include/httpd.h index 1c6a242a89..03b7751fee 100644 --- a/include/httpd.h +++ b/include/httpd.h @@ -249,6 +249,10 @@ extern "C" { #define DOCTYPE_HTML_4_0F "\n" +/** HTML 4.01 Doctype */ +#define DOCTYPE_HTML_4_01 "\n" +/** HTML 5 Doctype */ +#define DOCTYPE_HTML_5 "\n" /** XHTML 1.0 Strict Doctype */ #define DOCTYPE_XHTML_1_0S "\n\n" +#define DAV_RESPONSE_BODY_1 "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01//EN\" \"http://www.w3.org/TR/html4/strict.dtd\">\n<html>\n<head>\n<title>" #define DAV_RESPONSE_BODY_2 "\n\n

" #define DAV_RESPONSE_BODY_3 "

\n

" #define DAV_RESPONSE_BODY_4 "

\n" diff --git a/modules/examples/mod_example_hooks.c b/modules/examples/mod_example_hooks.c index da00b8c700..b6a12cb4b5 100644 --- a/modules/examples/mod_example_hooks.c +++ b/modules/examples/mod_example_hooks.c @@ -1007,7 +1007,7 @@ static int x_handler(request_rec *r) * Now send our actual output. Since we tagged this as being * "text/html", we need to embed any HTML. */ - ap_rputs(DOCTYPE_HTML_3_2, r); + ap_rputs(DOCTYPE_HTML_4_01, r); ap_rputs("\n", r); ap_rputs(" \n", r); ap_rputs(" mod_example_hooks Module Content-Handler Output\n", r); diff --git a/modules/generators/mod_autoindex.c b/modules/generators/mod_autoindex.c index c887056312..21fc59a011 100644 --- a/modules/generators/mod_autoindex.c +++ b/modules/generators/mod_autoindex.c @@ -179,7 +179,7 @@ static void emit_preamble(request_rec *r, int xhtml, const char *title) " <head>\n <title>Index of ", title, "\n", NULL); } else { - ap_rvputs(r, DOCTYPE_HTML_3_2, + ap_rvputs(r, DOCTYPE_HTML_4_01, "\n \n" " Index of ", title, "\n", NULL); diff --git a/modules/generators/mod_status.c b/modules/generators/mod_status.c index 5917953090..8e80202c44 100644 --- a/modules/generators/mod_status.c +++ b/modules/generators/mod_status.c @@ -412,7 +412,7 @@ static int status_handler(request_rec *r) ap_get_loadavg(&t); if (!short_report) { - ap_rputs(DOCTYPE_HTML_3_2 + ap_rputs(DOCTYPE_HTML_4_01 "\n" "Apache Status\n" "\n" diff --git a/modules/http/http_protocol.c b/modules/http/http_protocol.c index c52acf76d0..899fb787e3 100644 --- a/modules/http/http_protocol.c +++ b/modules/http/http_protocol.c @@ -1331,7 +1331,7 @@ AP_DECLARE(void) ap_send_error_response(request_rec *r, int recursive_error) */ ap_rvputs_proto_in_ascii(r, - DOCTYPE_HTML_2_0 + DOCTYPE_HTML_4_01 "\n", title, "\n\n

", h1, "

\n", NULL); diff --git a/modules/ldap/util_ldap.c b/modules/ldap/util_ldap.c index e9b25d9d41..e56041508f 100644 --- a/modules/ldap/util_ldap.c +++ b/modules/ldap/util_ldap.c @@ -173,7 +173,7 @@ static int util_ldap_handler(request_rec *r) if (r->header_only) return OK; - ap_rputs(DOCTYPE_HTML_3_2 + ap_rputs(DOCTYPE_HTML_4_01 "LDAP Cache Information\n", r); ap_rputs("

LDAP Cache Information" "

\n", r); diff --git a/modules/mappers/mod_imagemap.c b/modules/mappers/mod_imagemap.c index 8e76a089a6..e770dcf4e5 100644 --- a/modules/mappers/mod_imagemap.c +++ b/modules/mappers/mod_imagemap.c @@ -477,7 +477,7 @@ static void menu_header(request_rec *r, char *menu) { ap_set_content_type(r, "text/html; charset=ISO-8859-1"); - ap_rvputs(r, DOCTYPE_HTML_3_2, "\nMenu for ", + ap_rvputs(r, DOCTYPE_HTML_4_01, "<html><head>\n<title>Menu for ", ap_escape_html(r->pool, r->uri), "\n\n", NULL); diff --git a/modules/proxy/mod_proxy_balancer.c b/modules/proxy/mod_proxy_balancer.c index cbac1e16e7..419f25e41f 100644 --- a/modules/proxy/mod_proxy_balancer.c +++ b/modules/proxy/mod_proxy_balancer.c @@ -1564,7 +1564,7 @@ static void balancer_display_page(request_rec *r, proxy_server_conf *conf, } else { ap_set_content_type(r, "text/html; charset=ISO-8859-1"); - ap_rputs(DOCTYPE_HTML_3_2 + ap_rputs(DOCTYPE_HTML_4_01 "Balancer Manager\n", r); ap_rputs("