xsl:document not supported in apply/debug?
Having trouble installing Oxygen? Got a bug to report? Post it all here.
-
- Posts: 5
- Joined: Tue Jun 29, 2004 7:32 pm
xsl:document not supported in apply/debug?
hi all,
my xslt transformations are outputting multiple documents from a single xml input document by using the xsl:document element. while this works perfectly in saxon 6.5.2, it does not seem to work in oxygen, although i selected saxon as xslt processor.
any hints on what i am doing wrong, or is xsl:document not supported? (which would prohibit using oxygen for me and my institution)
regards,
flo
my xslt transformations are outputting multiple documents from a single xml input document by using the xsl:document element. while this works perfectly in saxon 6.5.2, it does not seem to work in oxygen, although i selected saxon as xslt processor.
any hints on what i am doing wrong, or is xsl:document not supported? (which would prohibit using oxygen for me and my institution)
regards,
flo
-
- Site Admin
- Posts: 2095
- Joined: Thu Jan 09, 2003 2:58 pm
Hi Flo,
Oxygen uses Saxon 6.5.3 and xsl:document works both from a transformation scenario and from the XSLT Debugger. There are however a couple of things you should pay attention at.
1. The stylesheet version must be different from 1.0, version 1.1 is recommended in order to have the xsl:document working [1],
2. You should make sure you are using Saxon as the XSLT processor in your transformation scenario and in debugging.
A working sample stylesheet is below:
[1] http://saxon.sourceforge.net/saxon6.5.3 ... l:document
Best Regards,
George
Oxygen uses Saxon 6.5.3 and xsl:document works both from a transformation scenario and from the XSLT Debugger. There are however a couple of things you should pay attention at.
1. The stylesheet version must be different from 1.0, version 1.1 is recommended in order to have the xsl:document working [1],
2. You should make sure you are using Saxon as the XSLT processor in your transformation scenario and in debugging.
A working sample stylesheet is below:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.1">
<xsl:template match="/">
<xsl:document href="c:/result.html">
<h1>RESULT</h1>
</xsl:document>
</xsl:template>
</xsl:stylesheet>
Best Regards,
George
-
- Posts: 5
- Joined: Tue Jun 29, 2004 7:32 pm
actually it's a path problem...
ah, i see... actually, it turned out to be a path problem... as the spec states, the output href is interpreted relative to the current working directory, which is c:\program files\eclipse in my case. that's were i found the output files...
any idea how to make it generate the output files in the directory of the source file? this would be a necessary enhancement, to provide some means of setting the working directory for xslt trafos.
regards,
flo
any idea how to make it generate the output files in the directory of the source file? this would be a necessary enhancement, to provide some means of setting the working directory for xslt trafos.
regards,
flo
-
- Site Admin
- Posts: 2095
- Joined: Thu Jan 09, 2003 2:58 pm
Hi Flo,
We pass the system IDs for for the source and the stylesheet documents when we run a transformation. It seems that the xsl:document uses the current directory to output the files. We cannot change that, one of the reasons is that in oXygen it is possible to run several transformations in the same time, therefore changing the current directory will break previously started transformations.
A possible solution is to pass the target directory as a parameter to your stylesheet and use that in the xsl:document/@href attribute as in the sample from the saxon documentation I quoted in the previous post:
<xsl:document href="{$dir}\preface.html">
Hope that helps,
George
We pass the system IDs for for the source and the stylesheet documents when we run a transformation. It seems that the xsl:document uses the current directory to output the files. We cannot change that, one of the reasons is that in oXygen it is possible to run several transformations in the same time, therefore changing the current directory will break previously started transformations.
A possible solution is to pass the target directory as a parameter to your stylesheet and use that in the xsl:document/@href attribute as in the sample from the saxon documentation I quoted in the previous post:
<xsl:document href="{$dir}\preface.html">
Hope that helps,
George
-
- Posts: 5
- Joined: Tue Jun 29, 2004 7:32 pm
hi,
i could work around the problem by using the approach you suggested. however, i have a RFE: it would be *amazing* if the output view would show the current output context (i.e. document) if the debugger is currently inside an xsl:document element.
i have no idea however how much effort it would be to implement this...
f/0
i could work around the problem by using the approach you suggested. however, i have a RFE: it would be *amazing* if the output view would show the current output context (i.e. document) if the debugger is currently inside an xsl:document element.
i have no idea however how much effort it would be to implement this...
f/0
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service