When distributing a framework to the users, it is a good idea to have the transformation scenarios already configured. This would help the content authors publish their work in different formats. Being contained in the Document Type Association the scenarios can be distributed along with the actions, menus, toolbars, catalogs, etc.
In the following section we will create a transformation scenario for our framework.
Create the directory xsl
in the directory frameworks/sdf
. The directory structure for our
documentation framework should be:
oxygen frameworks sdf schema css templates xsl
Create the sdf.xsl
file in the xsl
directory. The complete content of the sdf.xsl
file is found in the Example Files Listings.
Open the Document Type Associations. Open the Document Type dialog for the SDF framework then choose the Transformation tab. Click on the . In the Edit Scenario dialog, fill the following fields:
/ /The name of the transformation scenario. Enter SDF to HTML.
${frameworks}/sdf/xsl/sdf.xsl
Saxon 9B.
Change to the Output tab. Change the fields:
${cfd}/${cfn}.html
This means the
transformation output file will have the name of the XML
file and the html
extension and will be placed in the same directory.
Enable this option.
Enable this checkbox.
Now the scenario is listed in the Transformation tab:
To test the transformation scenario we created, open the SDF XML sample from the Example Files Listings. Click on the button. The Configure Transformation Dialog is displayed. Its scenario list contains the scenario we defined earlier SDF to HTML. Click on it then choose . The HTML file should be saved in the same directory as the XML file and opened in the browser.
![]() | Note |
---|---|
The key
|