Return-Path: Mailing-List: contact cocoon-dev-help@xml.apache.org; run by ezmlm Delivered-To: mailing list cocoon-dev@xml.apache.org Received: (qmail 7499 invoked from network); 26 Mar 2000 21:51:20 -0000 Received: from bureau6.utcc.utoronto.ca (128.100.132.16) by locus.apache.org with SMTP; 26 Mar 2000 21:51:20 -0000 Received: from cr473968-a.yec1.on.wave.home.com ([24.112.129.151] EHLO utoronto.ca ident: IDENT-NONSENSE [port 63440]) by bureau6.utcc.utoronto.ca with ESMTP id <464365-25107>; Sun, 26 Mar 2000 16:51:02 -0500 Sender: root@utoronto.ca Message-ID: <38DE84EB.D08647F9@utoronto.ca> From: root Reply-To: alex.muc@utoronto.ca X-Mailer: Mozilla 4.72 [en] (X11; U; Linux 2.2.12-20 i686) X-Accept-Language: en MIME-Version: 1.0 To: cocoon-dev@xml.apache.org Subject: Including XML and/or XSP in an XSP file Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Sun, 26 Mar 2000 16:50:51 -0500 X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Hi, There are a couple of messages from a little while back about the best way to include the output of one page into another. This is more or less a follow up to that. I would like to use the tag-lib that Stefano mentioned in his reply, but I am not having a lot of success. Can anyone answer the following questions: 1) From an XSP file can you include another XSP file, either through a call to or and have the included XSP file be processed as part of the calling XSP file? For this to work is it necessary to "strip-off" the XSP header stuff, like the XSP:page declaration and what not in the included XSP file? 2) If that is not possible can you, from an XSP file include the output XML of an XSP file? This would have to be done through a call like and not a file include so that the included XSP file can be processed by cocoon. When I try to do this the call to the uri works, but the output is then not formatted by the XSL Stylesheet in the calling XSP page. Does this have something to do with the output escaping problems of xerces in the cocoon1.1.7 distribution? Right now, I have the following XSP file called caller.xml The titel When I make a call to this page through cocoon via the url: http://192.168.0.4:8080/cocoon/pubs/caller.xml The following is returned instead of the actual contents of my test.xml file {unable to include: 'http://192.168.0.4:8080/cocoon/pubs/test.xml'} It seems like this must be a bug, because I know the file exists as I can call it through my browser without any problems. If that is the case I'd be willing to take a stab at fixing it, but ... I have taken a look at the source code and source xml files for the Util tag library. I can't really figure out what is what though. It seems like the same thing is sort of handled in two different places. There is both the org.apache.cocoon.processor.xsp.XSPUtil.java file and org.apache.cocoon.processor.xsp.library.java.util.xsl file. Both of them seem to have methods for including files. Can anyone tell me how these two files are related? And also which is used when I have in my XSP file? It might just be that these are two totally serparate files except for the fact that they share similar names, but I can't tell. Thanks for you help Alex.