Return-Path: Delivered-To: apmail-cocoon-dev-archive@www.apache.org Received: (qmail 71979 invoked from network); 7 Dec 2004 23:41:57 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 7 Dec 2004 23:41:57 -0000 Received: (qmail 23349 invoked by uid 500); 7 Dec 2004 23:41:52 -0000 Delivered-To: apmail-cocoon-dev-archive@cocoon.apache.org Received: (qmail 23278 invoked by uid 500); 7 Dec 2004 23:41:51 -0000 Mailing-List: contact dev-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: dev@cocoon.apache.org Delivered-To: mailing list dev@cocoon.apache.org Received: (qmail 23263 invoked by uid 99); 7 Dec 2004 23:41:51 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: neutral (hermes.apache.org: local policy) Received: from postfix3-1.free.fr (HELO postfix3-1.free.fr) (213.228.0.44) by apache.org (qpsmtpd/0.28) with ESMTP; Tue, 07 Dec 2004 15:41:50 -0800 Received: from [192.168.0.100] (lns-vlq-39f-81-56-134-235.adsl.proxad.net [81.56.134.235]) by postfix3-1.free.fr (Postfix) with ESMTP id BC956183206 for ; Tue, 7 Dec 2004 21:37:50 +0100 (CET) Message-ID: <41B6149D.1050202@apache.org> Date: Tue, 07 Dec 2004 21:37:49 +0100 From: Sylvain Wallez Organization: Anyware Technologies User-Agent: Mozilla Thunderbird 1.0RC1 (Macintosh/20041201) X-Accept-Language: en-us, en MIME-Version: 1.0 To: dev@cocoon.apache.org Subject: Re: Issue with cocoon views -- Bug or correct Design? References: <91ADE5AB-4888-11D9-A93D-000A95BED71E@alexnat.de> In-Reply-To: <91ADE5AB-4888-11D9-A93D-000A95BED71E@alexnat.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Thomas Alexnat wrote: > Dear Developers, > > I was asking in the cocoon user mailing list why my content is not > being transformed correctly, when using the cocoon default > pretty-print view. The answers so far pointed me to the developer > list, because there seems to be a misbehaviour or misunderstanding in > using the cocoon views concept. > > > P R O B L E M > ------------- > When calling a simple aggregated xml with the standard cocoon pretty > print view, it seems that cocoon calls the view transformer twice and > scrambles totally the output. > > http://localhost:8888/a?cocoon-view=pretty-content (works fine) > http://localhost:8888/b?cocoon-view=pretty-content (scrambles xml > tree, calls the view xslt twice!) > > > Q U E S T I O N > --------------- > How can I correctly get a view of the "b" matcher, by not scrambling > the previous included content from "a". Defining a seperate label for > each matcher does not seem to be a good and generic solution. > > > C O D E > ------- > > -- test.xml -- > > Hello World XML > > > > -- sitemap.xmap -- (added to the original sitemap) > > > > > > > > > Have you tried src="cocoon:raw:/a" here? "cocoon:raw" creates a new "naked request" where the parameters of the original request are ommitted, and maybe resets the view also (although I'm not sure after a quick look at EnvironmentWrapper). Otherwise, the view is called twice, and the result is the pretty-printing of the pretty-printed version of "test.xml". > > > > > > S Y S T E M > ----------- > Mac OS X 10.3.6 with Cocoon 2.1.6, Dual G5, Java 1.4.2_05 Wow, dual G5? Cool... Sylvain -- Sylvain Wallez Anyware Technologies http://www.apache.org/~sylvain http://www.anyware-tech.com { XML, Java, Cocoon, OpenSource }*{ Training, Consulting, Projects }