Page 1 of 1
Specifying Directory Paths
Posted: Tue Aug 03, 2010 4:11 pm
by kevin2010
We have multiple imports withing some xsl files. Some have paths names defines in a variable:
<xsl:import href="CONTENT:shared.xsl"/>
Is there a way to either define CONTENT to be point to the filepath, or remove the prefix CONTENT and setup oxygen to include the directory (and its xsl files)?
Regards
Kevin
Re: Specifying Directory Paths
Posted: Thu Aug 05, 2010 3:23 pm
by adrian
Hello,
I'm afraid you can't define a variable or parameter before the imports.
I guess you could use an XML catalog trick to get the imports from another location.
e.g. <xsl:import href="
http://mycontent/shared.xsl"/>
In an XML catalog you could put:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE catalog PUBLIC "-//OASIS//DTD XML Catalogs V1.1//EN" "http://www.oasis-open.org/committees/entity/release/1.1/catalog.dtd">
<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog">
<rewriteSystem systemIdStartString="http://mycontent" rewritePrefix="/my/file/location"/>
<rewriteURI uriStartString="http://mycontent" rewritePrefix="/my/file/location"/>
</catalog>
This means that SystemIDs and URIs that start with '
http://mycontent' will be redirected to '/my/file/location'.
Then you can add the XML catalog in Oxygen's options: Options -> Preferences -> XML -> XML Catalog
You can read more about catalogs here:
http://www.oxygenxml.com/doc/ug-oxygen/ ... alogs.html
Regards,
Adrian