|
![]() |
Pradeesh Pakkat wrote:please help me its really urgent...
Sorry for my emergency.Everyone's question on JavaRanch is urgent.
Why does displayStates() return a String?
Where does it get called? Have you checked the value of the states list after that invocation?
Pradeesh Pakkat wrote: As of my knowledge through Google is that we can't call jsp page directly after populating the list from the bean/action class.
When framework starts the display function will automatically populate the list, 'I think so'.
Now my question changed to 'HOW CAN WE CALL AN ACTION PAGE DIRECTLY'
There is no direct call to the JSP. If one were to invoke a JSP directly, there'd be no data to display.
Answer 1. "you don't want to" because it would break the MVC pattern.
Answer 2: "you can't" - see the top of this post. If the action sets up the data, calling the JSP directly will not work.
Answer 3: "you can't" because Struts tags throw an error if the Struts framework doesn't run first.
Joe Ess wrote:
You have made a really, really basic Java error in your action class. Please consider the questions I asked again.
Pradeesh Pakkat wrote:
by direct call to the jsp I mean the URL to be display in the address bar.
Joe Ess wrote
Why does displayStates() return a String?
Where does it get called? Have you checked the value of the states list after that invocation?
Joe Ess wrote
Think about how that list is accessed on the JSP.
Joe Ess wrote
You have made a really, really basic Java error in your action class.
Pradeesh Pakkat wrote:
Joe Ess wrote
You have made a really, really basic Java error in your action class.
I couldn't figure it out ...:-(
Bras cause cancer. And tiny ads:
Low Tech Laboratory
https://www.kickstarter.com/projects/paulwheaton/low-tech-0
|