cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robin Green" <gree...@hotmail.com>
Subject Re: Sharing XSP data between XSP pages?
Date Fri, 28 Apr 2000 12:12:50 GMT
"Yann" <ylelocat@ims.ltd.uk> wrote:
>Well, I currently have an XSP page that describe a web site menu. It 
>connects to a db so that some menu items appear or not according to the 
>user session profile.Each menu item links to another XSP page.
>
>What I want to achieve is something like a the menu XSP page beeing 
>included in all other XSP pages so that each page will have a menu. I don't 
>want to copy and paste the menu tags in each file.Even further, if I could 
>have my tag MENU having an attribute set by each XSP page that would be 
>even better (like which menu item is currently selected).
>
>Problem is: I don't have a clue on how to achieve this and I don't want to 
>defeat any of Coccon's purpose.
>
>Thanks,
>
>Yann (several days from finishing his first Cocoon-based web-app).

At first I thought "internal subrequests" - but no, that's a bad idea. 
Actually, this sounds like an ideal case for a logicsheet.

Here are some early docs from Ricardo (creator of XSP, AFAIK):

http://www.plenix.com/xsp/doc/logicsheets.html

Basically you put in your logisheet an xsl:template to substitute the menu 
tags wherever it sees the single tag <insert-menu> or whatever. Or even, you 
don't even need an insert-menu tag, just insert it at the appropriate place 
on the XML tree, if you know that is always going to be the same.



--
Robin

270+ Open Source Java links! 
http://directory.mozilla.org/Computers/Programming/Languages/Java/Open_Source/

________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com


Mime
View raw message