* [committed] wwwdocs: style: Simplify handling of <head> containers
@ 2022-10-21 7:14 Gerald Pfeifer
0 siblings, 0 replies; only message in thread
From: Gerald Pfeifer @ 2022-10-21 7:14 UTC (permalink / raw)
To: gcc-patches
This is the change actually triggering most of my changes the last week.
With that most of our web pages - the main page is still WIP - should now
pass validator.w3.org again:
Lose the trailing slash in <link rel="shortcut icon"> which we needed to
validate (most pages) as XHTML.
With that we no longer need to differentiate between XHTML and HTML pages
as much and can simplify the logic quite a bit. (Now only pages setting a
MetaHTML variable ADDSTYLE receive special treatment.)
---
htdocs/style.mhtml | 10 +++-------
1 file changed, 3 insertions(+), 7 deletions(-)
diff --git a/htdocs/style.mhtml b/htdocs/style.mhtml
index 08def35e..98641c25 100644
--- a/htdocs/style.mhtml
+++ b/htdocs/style.mhtml
@@ -1,13 +1,12 @@
;;; Set a couple of site-wide defaults, some of which we'll override in the
;;; following.
-<set-var NOSTYLE>
<set-var BACKPATH>
;;; The pages under install/ are generated from texinfo sources.
<if <match <get-var env::PREPROCESS_FILE> "install/.*">
- <unset-var NOSTYLE>
+ <set-var ADDSTYLE>
>
;;; Redefine the <head> tag so that we can add default <meta /> headers.
@@ -16,16 +15,13 @@
<verbatim>
<head>
</verbatim>
- <if <var-exists NOSTYLE>
- <group
- <link rel="shortcut icon" href="https://gcc.gnu.org/favicon.ico" />
- >
+ <if <var-exists ADDSTYLE>
<group
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
- <link rel="shortcut icon" href="https://gcc.gnu.org/favicon.ico">
<link rel="stylesheet" type="text/css" href="/gcc.css">
>
>
+ <link rel="shortcut icon" href="https://gcc.gnu.org/favicon.ico">
%body
<verbatim>
</head>
--
2.38.0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-10-21 7:14 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-21 7:14 [committed] wwwdocs: style: Simplify handling of <head> containers Gerald Pfeifer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).