how to include another XML document with XSLT?

Discussion in 'XML' started by Rosa, Aug 5, 2004.

  1. Rosa

    Rosa Guest

    hallo!

    it must be very easy, but I don't get the function document (explained
    in http://www.w3.org/TR/1999/REC-xslt-19991116#document) to work. I'm
    parsing an XML document with XSLT to write a text document and need to
    'input' extern xml files. The name of the externs file comes as
    attributes in of certain in the main XML file.

    Could somebody send me an example or an web-address with more
    explanations?

    Thanks,

    Rosa
     
    Rosa, Aug 5, 2004
    #1
    1. Advertising

  2. Rosa

    Peter Flynn Guest

    Rosa wrote:

    > hallo!
    >
    > it must be very easy, but I don't get the function document (explained
    > in http://www.w3.org/TR/1999/REC-xslt-19991116#document) to work. I'm
    > parsing an XML document with XSLT to write a text document and need to
    > 'input' extern xml files. The name of the externs file comes as
    > attributes in of certain in the main XML file.
    >
    > Could somebody send me an example or an web-address with more
    > explanations?


    <xsl:variable name="somedata"
    select="document('somefile.xml')/foo/bar/blort"/>

    ///Peter
    --
    "The cat in the box is both a wave and a particle"
    -- Terry Pratchett, introducing quantum physics in _The Authentic Cat_
     
    Peter Flynn, Aug 6, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Tony Prichard
    Replies:
    0
    Views:
    754
    Tony Prichard
    Dec 12, 2003
  2. Phil
    Replies:
    3
    Views:
    571
    Janwillem Borleffs
    May 27, 2004
  3. Replies:
    4
    Views:
    691
  4. jkflens
    Replies:
    2
    Views:
    1,513
    jkflens
    May 30, 2006
  5. Andreas Bogenberger
    Replies:
    3
    Views:
    957
    Andreas Bogenberger
    Feb 22, 2008
Loading...

Share This Page