Dave Newton on 20/04/08 02:24, wrote:
--- Adam Hardy <[EMAIL PROTECTED]> wrote:
What you're saying is clear except one thing - in JSTL I can access the
action. And in JSTL, I'm not calling request.getAttribute() - I'm _not_
doing this:
${requestScope['myObject']}
I'm just doing this:
${myObject}
and struts somehow gives me the right info, which to my mind means that
Struts has put that object into the PageContext already.
I told you precisely what it did: if the request wrapper can't find the
attribute in normal scope, it goes to the stack.
Here is the entire relevant source; it's 36 lines. With comments.
public Object getAttribute(String s) { [snip]
OK mystery over - I just didn't see how the JSP gets to the request wrapper to
make that call to request.getAttribute().
I just realised though - the PageContext will search through all scopes,
starting with the Request until it finds what you asked for. Unless you specify
PageContext.SESSION_SCOPE or other.
Sorry for the misunderstanding.
Adam
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]