ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Koberg" <...@koberg.com>
Subject RE: XML, XSL, and Ant
Date Wed, 22 Oct 2003 12:53:26 GMT
Hi,

You should be able to use a 'global' xsl include that imports/includes the
common xsl files. This way you do not need to use entities.

So you have something like:

- primary1.xsl
  - xsl:include href=global.xsl
     - xsl:include href=a.xsl
     - xsl:include href=b.xsl

- primary2.xsl
  - xsl:include href=global.xsl
     - xsl:include href=a.xsl
     - xsl:include href=b.xsl

But, your way *should* work. If not, it is a bug in the catalog resolver.
Are you using the latest one? There was a release a few days ago.

Best,
-Rob

> -----Original Message-----
> From: Kyle Adams [mailto:kadams@gfs.com]
> Sent: Wednesday, October 22, 2003 5:45 AM
> To: user@ant.apache.org
> 
> _____
> 
> Kyle Adams | Java Developer  |  Gordon Food Service  |  616-717-6162
> >>> shennessy@goldenhourdata.com 10/21/03 20:17 PM >>>
> Somewhere, like my-style.xsl, there is a declaration of the xsl namespace?
> <xsl:stylesheet version="1.0"
> xmlns:xsd="http://www.w3.org/2000/10/XMLSchema"
> xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
> >>>
> 
> Ah yes - good point.  In simplifying my stuff for posting, I simplified
> the namespace declaration right out.
> 
> Below is the corrected stylesheet:
> 
> my-style.xsl
> ==
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE xsl:stylesheet [
> <!ENTITY templates PUBLIC "Snap Template Index" "file:index.ent"> ]>
> <xsl:stylesheet
>     xmlns:xsd="http://www.w3.org/2000/10/XMLSchema"
>     xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
>     version="1.0">
> ...
> &templates;
> ...
> 
> I'm having two, separate problems, the first one being the more serious of
> the two:
> 
> 1) Getting the external entity to resolve using <xmlcatalog> on the
> <style>.  Does the <xmlcatalog> only apply to the source XML file, or does
> it also apply to the XSL?
> 
> 2) Getting warnings "Element type 'xsl:xxxxx' must be declared".  The
> transformation is still successful, so my working assumption right now is
> that these warnings are generated by some validating feature of Xalan, and
> that I should be able to turn validation off to eliminate those warnings.
> 
> Thanks,
> Kyle



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message