我需要一个样式表来转换我的 docbook xml 文件,以便它们现在将 xml:base 元素包含到我的部分标签中。我该怎么做(因为 xml:base 需要系统和节点信息???)
输入:
<section xmlns="http://docbook.org/ns/docbook" xml:id="voidVisit" version="5">
<title>Void</title>
<section>
<title>Screenshot</title>
<mediaobject>
<imageobject>
<imagedata fileref="screenshots/Dialog.png" />
</imageobject>
</mediaobject>
</section>
</section>
输出:
...
<section xml:id="void" version="5"
xml:base="file:/C:/Projects/my/proj/trunk/spec/module/components/void.xml">
<title>Void</title>
<section>
<title>Screenshot</title>
<mediaobject>
<imageobject>
<imagedata fileref="screenshots/Dialog.png"/>
</imageobject>
</mediaobject>
</section>
...