Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有许多 XML 文件,它们被组织到不同的目录中。我需要组合它们并使用 XSLT 转换结果。到目前为止,我已经这样做了,除了一个问题:需要先转换一些 XML 文件才能将其包含到结果中。xinclude 似乎忽略了 xml-stylesheet 声明。
在 xincluded 之前如何转换 XML 文件?
问候,
[西蒙.cpu]
将其分解为多个转换调用,首先准备 xml 文件,然后进行主要转换。
流程如何运行?有一个Makefile或类似的东西?在这种情况下,在包含之前添加对 xsltproc 的显式调用,然后 xinclude xsltproc 的输出。
Makefile
如果 xsltproc 可以读取处理指令(xml-stylesheet请注意,我没有对此进行测试),您甚至不必明确指出要使用的样式表。
xml-stylesheet