On Sun, Jan 14, 2001 at 06:30:15PM -0500, Steve Tinney ([EMAIL PROTECTED]) wrote:
> sungod wrote:
> > > use  <xsl:copy-of select='document("somexmldocument.xml")'/>
> > >
> > > and use this method to create a sourcexml of all your children, then
> > > apply another xsl transformation for styling to that 'big; file
> > 
> > I thought about doing this, but there's a drawback here: when I get this technique 
>working with my news site, I want to apply it also to a library of e-books I'm making 
>from texts I get at Project Gutenberg. These books can be several hundred kilobytes 
>in length, and I really don't want to subject my system to the overhead incurred in 
>concatenating all of them together just to get title and author information from them.
> > 
> > Instead, I need to use an element that does the same operation as <xsl:copy-of> 
>but which also applies the transformation instructions inside that element. I thought 
><xsl:template> would do this, and again, my question is unanswered: is Sablotron 
>SUPPOSED to do this, or am I misunderstanding?
> 
> 
> It sounds like you want something like:
> 
>       <xsl:for-each select="document('somedoc.xml')">
>           <xsl:apply-templates select="/metadata/author"/>
>         </xsl:for-each>

This is very close to what I was looking for, and is usable for my job. Thanks very 
much for the suggestion.

> But maybe you should be thinking of ripping out the often-needed
> metadata and caching it in a separate doc with xlinks pointing to the
> document the metadata refers to?

I also think that's probably the best way, but with the very slim support for XLink in 
end-user tools thus far, I was hoping for some way to eliminate that dependency. 
Someday if IE AND Netscape support XLink in addition to XSL, I'll probably move to 
that approach. In the meantime, since both are working to include support for XSLT 
first, it's good to know that it can be done.

> > I apologize if my asking for XSLT help is off-topic here, but since it is 
>>resulting in a Sablotron crash, hopefully it can be used to clean up a bug >or two.
> 
> True, but at this stage of the game it seems only fair to me to try to
> feed Sablotron slightly less arbitrary input (I don't mean that Sab
> shouldn't have to deal with incorrect input, only that I would prefer
> that more effort go into implementing missing features right now).

I understand, but in that vein, I'd like to congratulate Sablotron developers for 
making a tool that "mere users" ;) like me CAN use to learn XSLT techniques. The 
options so far are kind of slim, and Sablotron, in my experience, presents the 
simplest and most trouble-free option for testing my work.

> A good thing to do is to use several XSL processors as a check on your
> input. Michael Kay's Saxon is excellent at both conformance and
> error-checking/reporting.

Thanks; I'll look into it. Tools I've had difficulty with include 4Suite's 4xslt, and 
Clark's XT. As I've said, Sablotron so far has been best, so for indulging my neophyte 
questions, a big THANKS, and again, for the quality product, congratulations all.

-- 

"The robber baron's cruelty may sometimes sleep, his cupidity may at some
point be satiated; but those who torment us for our own good will torment us
without end for they do so with the approval of their own conscience."
                                                                -C. S. Lewis
----------------------------------------------------------------------------
[EMAIL PROTECTED]

Reply via email to