Dear All

I am relatively new to using struts tiles and I am
having a problem trying to figure out how to do the
following:

I have an action that returns the news where the users
submits a form specifying the subject category and
date.  The action finds the relevant news and then
forwards it to a view page to be displayed for the
user.  This works.

Now I would like to re-use the action but this time I
know in advance what subject category and date need to
be displayed.  I want to insert the tile into another
page.

I have tried the following but it does not work:

<tiles:insert page="/getnews">
        <tiles:put name="category"  value="${val.category}"
/>
        <tiles:put name="bean" beanName="GetnewsForm"/>
</tiles:insert>                 
This just makes the bean available to the tile for use
inside the that jsp.

However the above does not cause the “form” to be be
populated, infact no form is passed to  the action
i.e. It is  null.

How would I insert the results of an action into a jsp
which uses parameters harvested from that jsp which
are used to populate the form?  I.e. How do I
programmatically cause a form to be created that is
passed to the action from a tiles:insert (or similar)?

I thought about having a separate jsp page that has
<html:form action= with html:hidden parameters made
available to it by the tiles:put from the original
insert. But I could not figure out how to
automatically make that page execute the submission
without waiting for the user to press the submit
button.

Any help will be greatly appreciated.

Thanks in advance.

__________________________________
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to