Remove an invalid attribute in longindex.html

For some reason, the stylesheets generate a
<div xmlns:xlink="http://www.w3.org/1999/xlink" ...> element in
longindex.html, but this is not valid in xhtml (the attribute
xmlns=xlink is not defined in the DTD). The problem is that tidy then
thinks it is not a true xhtml and removes the doctype declaration.
But when a browser receives a file without doctype declaration, it
thinks it uses an old standard, and switches to "quirks mode"
(for firefox, this can be seen by typing ctrl-I on the page).
This commit is contained in:
Pierre Labastie 2024-01-14 22:27:37 +01:00
parent ec18a3872a
commit 855d0c9574

View File

@ -48,6 +48,7 @@ book: validate profile-html
$(Q)mkdir -p $(BASEDIR)/stylesheets
$(Q)cp stylesheets/lfs-xsl/*.css $(BASEDIR)/stylesheets
$(Q)sed -i 's|../stylesheet|stylesheet|' $(BASEDIR)/index.html
$(Q)sed -i 's/xmlns:xlink.*xlink"//' $(BASEDIR)/longindex.html
$(Q)mkdir -p $(BASEDIR)/images
$(Q)cp images/*.png $(BASEDIR)/images