You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by James Milillo <bi...@attbi.com> on 2003/06/17 18:08:44 UTC
Setting values
*Sorry if this is a repeat, I posted from my newsgroup client early this
morning, but have not seen the message appear yet, so I'm sending this again
through mail*
Hi,
I'm looking for help on something that I thought would be pretty simple.
Here's a short example of what I'm trying to accomplish:
I have an application that deals with People. The operations available are
Add, Search, and View. For each operation, I have a separate .jsp page
(addPerson.jsp, searchPerson.jsp, viewPerson.jsp) and I also a person.jsp
which contains the following:
<bean:message key="person.fname"/>:<html:text property="firstName"/>
<bean:message key="person.lname"/>:<html:text property="lastName"/>
etc, etc.
Now addPerson and searchPerson were simple, and after doing page specific
things I could simply do
<%@ include file="person.jsp"%>
The problem arises when I try to implement viewPerson, I want to use the
same include statement, but I want to put values into the text fields. I
have tried to set the values in a ViewPersonForm object from my
SearchPersonAction, but that has not been working for me. I have not been
able to find any tutorials that address this either.
Obviously the reason I want to do this is to avoid making changes in 3+
files if another field is added to a Person. If anyone had done this before
I would greatly appreciate any help. Thank you in advance.
Kind regards,
-Jim
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org