On 5/11/06, A. Alonso Dominguez <[EMAIL PROTECTED]> wrote:
Hi there,

I'm posting this message because I'm begining to test the new Struts-Action 1 snapshot releases, specifically the new Struts-Faces project and MyFaces 1.1.2.

Then, when I tried to submit a struts based form bean I found out that the request parameters wasn't populated to ActionForm instance.

Taking a look to the HTML code generated from the renderers, I found that the 'name' attribute of my input fields are being rendered as 'body:logonForm:username', exactly same value as the 'id' attribute.

I know that this problem appears since myFaces 1.0.9, take a look to the following issue:
http://issues.apache.org/struts/browse/STR-2856

I this really intended?, I couldn't see any issue posted on MyFaces JIRA about this so I'm a bit confused.

Is this a problem of Struts-Faces or MyFaces???

If you are planning on using the Struts-Faces integration library, then you should do form bean population the "JSF way" instead of the "Struts way".  In other words, declare your ActionForm bean to be a managed bean in faces-config.xml, and then use value binding expressions in the input components inside your page to bind to the property values of this form bean.  It's also quite convenent to use the same bean for your actions as well ... the "Struts-Faces Example Application #1" example app shows you how to do this.  It's the good old "Struts MailReader" example, converted to use JSF techniques.

Any help on this will be appreciated..

Regards,
Alonso

Craig

Reply via email to