So you want to reuse some JSP piece? You can do this:
<ww:push value="bean"> <ww:include page="bean.jsp"/> </ww:push> Then your bean.jsp can just access the properties directly, like this: <ww:property value="prop1"/> And, because the bean is pushed onto the value stack, it will find the properties there.... In your second page, you just push on "bean2" instead. Jason > -----Original Message----- > From: Jan-Peter Hagenm�ller [mailto:[EMAIL PROTECTED] > Sent: Friday, January 09, 2004 11:06 AM > To: [EMAIL PROTECTED] > Subject: [OS-webwork] reuse Beans in ActionSupport classes and jsp > > > > hi > > i want to reuse some beans in my ActionSupport classes like: > > class MyActionSupport extends ActionSupport { > MyBean Bean = new MyBean(); > public getMyBean() {retun MyBean();} +setter > public String execute() { ... } > } > > and i want to reuse the ui component e.g. as in a jsp for > MyActionSupport like ... <input type="text" name="bean.prop1" > value="<ww: property value="bean.prop1"/>" > > if a have a reference called Bean2 in another ActionSupport > class i cannot (re)use the ui component because i rely on > "bean.prop" and not on "bean2.prop" > > if i take prop1 without bean(2).prop1 it won't work i think. > > are there any typically practices where i need only one > generally ui component ? > > thanks! > > jp > > > > > > > ------------------------------------------------------- > This SF.net email is sponsored by: Perforce Software. > Perforce is the Fast Software Configuration Management System > offering advanced branching capabilities and atomic changes > on 50+ platforms. Free Eval! > http://www.perforce.com/perforce/loadprog.html > > _______________________________________________ > Opensymphony-webwork mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork > ------------------------------------------------------- This SF.net email is sponsored by: Perforce Software. Perforce is the Fast Software Configuration Management System offering advanced branching capabilities and atomic changes on 50+ platforms. Free Eval! http://www.perforce.com/perforce/loadprog.html _______________________________________________ Opensymphony-webwork mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
