Srinivas--

 Hey -- good questions.  Comments below...


Don't you think that  actionForm should be available in requestScope whether
it is jsp, <jsp:include> or tag files?


Actually, I'd prefer to leave this behavior as-is since it's how
Struts does things (and NetUI is based on Struts after all).  :)
Struts puts the action form in the request until the <form> tag when
it appears as a PageContext attribute until the closing </form> tag.

If "actionForm" were always in the request, it would be data bindable
outside of a <netui:form> tag, which seems odd.  Apparently, Struts
took the same stance which is why it's stored in a Struts-specific
attribute name.  In cases where you need actionForm as an implicit
object, it can be accessed from the request attribute where Struts
leaves it.  For file includes and .tag files, it should be available
as an implicit object.

I'm not totally wedded to this, but it seems like a reasonable
behavior.  I'd probably switch away from using <jsp:include>s to .tag
files as the latter work "better" in the 2.0 container.  At least,
that's my $0.02...  :)


${dataGrid} is also not working in JSP tag files

We customized the sort and page using tag files and we have to explicity
pass the dataGrid as the attribute to the tag files

Exactly -- this is because it's a PageContext scoped attribute
(implicit object).  Personally, I'd rather not put every attribute in
the request so that it's globally visible to <jsp:include>s and .tag
files.  This feels a little too much like global variables to me.  :)

Passing the dataGrid to the tag files as you've done seems like the
right way to go.  This makes the contract between the tag file and a
page that uses it very explicit and probably makes it easier to debug.

Hope that helps!

Eddie

Reply via email to