Well, there is a way in MyFaces to do so.

check out the t:aliasBean!

regards,

Martin

On 8/26/05, Udo Schnurpfeil <[EMAIL PROTECTED]> wrote:
> > * The fact that you can use a value binding expression on nearly
> >   every attribute makes using rt expressions redundant ... you can
> >   do anything you need with a value binding anyway.
> 
> A very powerful feature in JSP 2.0 are "Custom Tags".
> 
> Having a bean Foo in your application with several instances.
> Now you write some code to edit this bean. If you put this code
> into a custom tag like
> 
> WEB-INF/tags/beans/foo.tag begin ------------------------------
> 
> <%@ attribute name="bean" %>
> <h:outputLabel value="here comes my bean: " />
> <h:inputText value="#{${bean}.firstName}" />
> <h:inputText value="#{${bean}.secondName}" />
> 
> foo.tag end --------------------------------
> 
> you can use this snip many times on your jsp like
> 
> page.jsp begin ------------------------------
> 
> <%@ taglib tagdir="/WEB-INF/tags/beans" prefix="beans" %>
> <beans:foo bean="foo1" />
> <beans:foo bean="foo2" />
> <beans:foo bean="foo3" />
> 
> page.jsp end --------------------------------
> 
> Unfortunately this does not work. Because of the rtexpression=false.
> 
> In tobago we decided to enable the feature, to make such things work.
> 
> Is there a way in JSF 1.2 / JSP 2.1 to make such sniplets run without
> dublicating code?
> 
> Udo
> 
> > In JSF 1.2 / JSP 2.1, the concepts are getting unified ... but in the
> > mean time (when the JSP container doesn't know what a value binding
> > expression is) this was the decision made at the JSF spec level.
> >
> >
> > Craig
> >
> 
> 


-- 

http://www.irian.at
Your JSF powerhouse - 
JSF Trainings in English and German

Reply via email to