> -----Original Message-----
> From: Hollaway, Shedrick CIV (TRFKB C600)
> [mailto:[EMAIL PROTECTED]
> Sent: Thursday, August 12, 2004 8:28 AM
> To: 'Struts Users Mailing List'
> Subject: RE: Multiple forms in one JSP + one Action
> 
> 
> Rick, my apologies for being unclear here, html:text is 
> html-el:text and I
> am using JSTL to retrieve data and iterate with (c:foreach). 
> There are alot
> more fields involve here each ActionForm corrolate to a database
> tables(Atable = Aform, Btable = Bform). I would like the user 
> to be able
> update fields in multiple tables without binding the table in 
> one very big
> ActionForm. Does this fit the exception of nested forms using JSTL?

I don't know.. but what you're trying makes no sense from an engineering point of 
view... Form objects are not meant to represent tables... they are view only 
objects... it's up to your action class to then map the view to the database ( or, 
better, translate the view to 1+ value objects, call your business object which n 
turns actually handles manipulating the DAO objects), not the other way around.

If you follow that, then this entire thread becomes moot, because you're using struts 
as it was designed to be used.


> 
> Shed
> 
> > Wy would you want to? Why don't you just make an ActionForm 
> with the 
> > properties:
> > 
> > firstName
> > lastName
> > homePhone
> > contact1
> > contact2
> > 
> > Maybe I'm missing something:) Also you do know that 
> > <html:form> will not 
> > work defined like you have it?
> > 
> > Also of course you need your submit button inside the form. 
> > Lastly you 
> > have two form fields named the same (fullName) which will end up 
> > submitting a String[] which is probably not what you want. 
> > Make one form 
> > and name them contact1 and contact2 and set them before you 
> > get to the 
> > form so you don't have to declare the value like you are 
> doing. (You 
> > 'usually' want to avoid having to declare the value - it 
> > should be set 
> > in the form. There are exceptions - nested forms using JSTL, 
> > sometimes 
> > radio or checkboxes - but 99.9& of the time you shouldn't 
> > need to define 
> > the value using an html:text tag).
> > 
> > 
> > -- 
> > Rick
> > 
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

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

Reply via email to