cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jan Hoskens>
Subject Sessioncontext/authenticationcontext + JX
Date Thu, 06 Jan 2005 12:46:06 GMT

As I'm trying to reduce/replace my XSP pages (mainly) by switching to 
flow/jx I was experimenting on how I could grab some information from a 
sessioncontext and my authenticationcontext. I had an "Info" XSP page 
with a pipeline that's used by my overal page layout (think of user info 
that's visible at all times or are adapted while progressing through the 
site). In that page I called the <xsp-session-fw:...> sheet to 
accomplish this.

To replace my xsp (I want to stick with jx/flow now) I thought of some 
possibilities like:
- write an action and set a variable (eg in request) containing an xml 
structure that will be included in the overal layout
- write a transformer/generator to create the xml structure.
- the info pipeline calls a flow to extract the info vars and a jx 
infopage includes these variables in an xml structure.

But at the end, I stumbled upon this (using jexl in a jx page):

which works fine and I can use this in my overal page layout as this is 
a jx page with includes to fetch the actual page. (so I'm having one 
pipeline, the "info-pipe", less than usual)

Now I'm posting this for several reasons:

1) you may have the same problem fetching the 
sessioncontext/authentication, so this may be interesting for you to use.
2) I'm wondering if I'm forgetting something here that makes this 
construction hazardous.
3) and finally: maybe it's interesting to have another variable 
"cocoon.sessioncontext" available to be able to create constructions 
such as: ${cocoon.sessioncontext.mycontextname.somepath} and maybe the 
same for authentication (but that one's a block, so I'm not sure).

Does this make any sense?

Any comments are welcome!

Kind Regards,

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message