cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joerg Heinicke <joerg.heini...@gmx.de>
Subject Re: lost session attribute with document()..please help
Date Sun, 30 Nov 2003 10:18:16 GMT
On 30.11.2003 01:21, Nadia BrĂ¼nning wrote:

> i have a strange problem:
> i have an xsp-file result.xsp:
> ......
> request.getSession();
> <esql:execute-query>
> <esql:query>insert into user values('','<session:get-attribute
> name="Username"/>',2,2)</esql:query>
> <esql:error-results>
> </esql:error-results>
> </esql:execute-query>
> 
> when i call this file (http://localhost:8888/api/result.xsp) the result will
> be saved in the db without problems but:

You request this file without any session, so where should this 
information come from?

> if i call this file from an xslt-sheet, the db-value for the
> Username-attribute is always null. it seems that the session-attribute is
> lost or something like that, but why?
> here is a snipet from my xslt:
> .......
> <xsl:variable
> name="file">http://localhost:8888/api/result.xsp</xsl:variable>
> <xsl:apply-templates select="document($file)"/>
> .......

You can use an internal Cocoon request, the session should not get lost 
then. It's to be done using cocoon: protocol and an appropriate matcher 
in the sitemap. You should later put this matcher into a pipeline with 
@internal-only="true", so that it's not accessible from outside.

Joerg


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message