This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Struts and the fly likes dynamic bean:define tags Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "dynamic bean:define tags" Watch "dynamic bean:define tags" New topic
Author

dynamic bean:define tags

Pavan Tummala
Ranch Hand

Joined: Dec 25, 2004
Posts: 74
Hello,
I have a bean named navigation in application-context and I can access it in the jsp using: <bean efine id="navigation" name="navigation" />

There can be mulitple navigation beans in the context. Each of them r distinguished by a tailing ID number( for example navigation1,navigation2..1,2 are the id's here)
The ID number is dynamic and is stored in the session.
I want to be able to access the appropriate bean according to the Id in session. Something like:
<bean efine id="navigation" name="navigation"+id />

This can achieved esily using scriplets but I would like to avoid it.

Any information regarding this would be appreciated.

Pavan.


If Java had true garbage collection, most programs would delete themselves upon execution -- Robert Sewell
 
Consider Paul's rocket mass heater.
 
subject: dynamic bean:define tags
 
Similar Threads
Accessing bean in logic Tag
Accessing an element of a list, whose position is given as URL parameter
bean:define not working in logic:iterate
Using bean:define
bean:define tag