cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ralph Goers" <Ralph.Go...@dslextreme.com>
Subject Re: Getting a session attribute
Date Thu, 04 Nov 2004 17:36:14 GMT
Never mind.  We got it to work with
{session:substring(getAttribute(.,'key'),1,3)}


Ralph Goers said:
> He is doing that.  What he is really unhappy with, I guess, is that he
> would really like to just be able to do a substring operation on the
> result of session-attr input module; like{session-attr:substring(key,1,3)}
>  or {jxpath:substring({session-attr:key},1,3}.  It looks like the first
> syntax would require that the session-attr input module extend jxpath
> while the second requires nested input modules, which I don't believe we
> support.
>
> Ralph
>
>
> Leszek Gawron said:
>> Ralph Goers wrote:
>>> One of my co-workers wants to use the session module to retrieve a
>>> session
>>> attribute. He does not want to use the session attribute module because
>>> he
>>> needs to do a substring on the returned value, which JXPath will let
>>> him
>>> do.  Unfortunately, we cannot figure out what syntax will successfully
>>> return a session attribute from the session input module.  Any ideas?
>> Have you tried using JXPathMetaModule?
>>
>> http://cocoon.apache.org/2.1/apidocs/org/apache/cocoon/components/modules/input/JXPathMetaModule.html
>>
>> Class description gives me an impression that this will work.
>>
>> --
>> Leszek Gawron                                      lgawron@mobilebox.pl
>> Project Manager                                    MobileBox sp. z o.o.
>> +48 (61) 855 06 67                              http://www.mobilebox.pl
>> mobile: +48 (501) 720 812                       fax: +48 (61) 853 29 65
>>
>
>


Mime
View raw message