CLEANUP: stats: use modern DOCTYPE tag

Switching the stats page doctype to the modern standard is shorter and
less complex, and is the recommended doctype by current HTML standard.
It makes it clear that we do not want to run in quirks mode. More information below.

Quirks mode: https://developer.mozilla.org/en-US/docs/Web/HTML/Quirks_Mode_and_Standards_Mode
HTML Standard: https://html.spec.whatwg.org/multipage/syntax.html#the-doctype
This commit is contained in:
Nicolas CARPi 2024-08-20 15:12:23 +02:00 committed by Willy Tarreau
parent c63d558e41
commit 9318a624a1

View File

@ -59,8 +59,7 @@ void stats_dump_html_head(struct appctx *appctx)
/* WARNING! This must fit in the first buffer !!! */
chunk_appendf(chk,
"<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\n"
"\"http://www.w3.org/TR/html4/loose.dtd\">\n"
"<!DOCTYPE html>\n"
"<html><head><title>Statistics Report for " PRODUCT_NAME "%s%s</title>\n"
"<link rel=\"icon\" href=\"data:,\">\n"
"<meta http-equiv=\"content-type\" content=\"text/html; charset=iso-8859-1\">\n"