Hello Benjamin,
Interesting problem.
Would it not suffice to just agree on a specific syntax for this with your content editors, like:
* "Hi ${user},*
this is your personal portal-page!"(or something less developer oriented / more HTML-like).
Then, you just need to write a special routine (either in jsp or java class) that 'preprocesses' a text field by replacing occurrences of the ${user} token with the name of the current user. Call this routine from your templates for all text fields for which this should be enabled and you are set, I would think.
Yours, Jurjan-Paul
[EMAIL PROTECTED] wrote:
Hi,
we would like that the content editor is able to write a greeting text, like:
*"Hi Phillippe,* this is your personal portal-page!"
So instead of the user name, he would use a placeholder, which could even be a HTML tag.
The solution you described me doesn't help me as the text "Current user is:" is hardcoded, but I want the content editor decide what he wants to write. It is not solvable with the box type as boxes or their content cannot be concatenated. It is always another box, what is created.
Do you have another idea if this requirement could be solved easily?
Benjamin Papez
System Architect *************************************************** COMMARO mobile trading systems GmbH Kohldorfer Strasse 98 A-9020 Klagenfurt - Austria/Europe
phone: +43 (463) 298505 fax: +43 (463) 298505-22 ***************************************************
Philippe Vollenweider <[EMAIL PROTECTED]> wrote on 23.06.2004 16:55:11:
> Hello,
>
> You can add a new box type called "user".
>
> To do this, just add a new element "user" to the array list boxTypes
> (include/declaration.inc) then, on box.jsp, add something like this:
>
> <bean:define id="user"
> value='<%=ResourceBundleMarker.drawMarker(resBundleID,"user","")%>'/>
>
> ...
>
> <c:when test="${boxTypeValue == user">
> Current user is : <%=jData.params().getUser().getUsername()%>
> </c:when>
>
> Philippe.
>
> At 22.06.2004 12:06, you wrote:
>
> >Would it be possible to give the content editor the ability to decide,
> >where the name of the current user should be inserted (like in the welcome
> >text) or is this only possible hardcoded in the JSP?
> >
> >Greetings,
> >Benjamin Papez
>
> -------=[ pvollenweider at jahia dot com ]=---------
> Jahia : A collaborative source CMS and Portal Server
> www.jahia.org Community and product web site
> www.jahia.com Commercial services company
>
>
-- ----- ---- --- -- - - - - - - - - J.P. Medema E: [EMAIL PROTECTED] ----- ---- --- -- - - - - - - - -
