Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bogus xmlns:xlink attribute leaked into HTML output when <index> was used. #239

Open
anarazel opened this issue Feb 13, 2022 · 1 comment

Comments

@anarazel
Copy link

Hi,

In postgres' sgml docs I noticed 100kB+ of xmlns:xlink=..., which turns out to be caused by autoidx.xsl not including xlink in exclude-result-prefixes. Previously reported at https://sourceforge.net/p/docbook/bugs/1384/

Because postgres customizes the bookindex output, including outputting the <div class="index"> , the xmlns:xlink gets pushed down into the elements that autoidx emits. Leading to output like this:

        <div class="indexdiv" id="indexdiv-A">
          <h3>A</h3>
          <dl>
            <dt xmlns:xlink="http://www.w3.org/1999/xlink" id="ientry-idm19499">abbrev, <a class="indexterm" href="functio
ns-net.html">Network Address Functions and Operators</a></dt>
            <dt xmlns:xlink="http://www.w3.org/1999/xlink" id="ientry-idm86953">ABORT, <a class="indexterm" href="sql-abor
t.html">ABORT</a></dt>
            <dt xmlns:xlink="http://www.w3.org/1999/xlink" id="ientry-idm11113">abs, <a class="indexterm" href="functions-
math.html">Mathematical Functions and Operators</a></dt>
            <dt xmlns:xlink="http://www.w3.org/1999/xlink" id="ientry-idm3024">ACL, <a class="indexterm" href="ddl-priv.ht
ml">Privileges</a></dt>

Not fun :)

Should I open a pull request with the obvious change? Or would you prefer to take it from https://sourceforge.net/p/docbook/bugs/1384/?

Regards,

Andres

@bobstayton
Copy link
Contributor

bobstayton commented Feb 14, 2022 via email

Gusse500 added a commit to Gusse500/LFS-Norsk that referenced this issue Jan 18, 2024
Malen kalt generate-basic-index i
{docbook-xsl}/xhtml/autoidx.xsl har en feil som genererer et div-element
med feil xmlns:xlink-attributt. Se
docbook/xslt10-stylesheets#239.
I stedet for å fikse docbook-xsl, som ville fungere bare i LFS (men vi
ønsker å kunne gjengi på andre distroer), kopier den defekte malen
til våre tilpasningsfiler (lfs-index.xsl), slik at denne brukes.
Vi kan også forenkle det mye siden vi ikke trenger alle sakene
dekket i generate-basic-indexl.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants