The only thing to be aware of is to not collide your manually created text
fields' names with those selected by Tapestry for the form elements.  I.e.,
if you have a component with id "userName" don't create a manual text field
with name="userName".  They'll collide and confuse things.

On 10/12/07, Jean-Philippe Steinmetz <[EMAIL PROTECTED]> wrote:
>
> Thanks again. I went with the second suggestion and it works beautifully.
>
> Jean-Philippe
>
> > -----Original Message-----
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> > On Behalf Of Josh Canfield
> > Sent: Friday, October 12, 2007 3:37 PM
> > To: Tapestry users
> > Subject: Re: T5: Form not saving all elements
> >
> > You can grab the the parameters directly from the request
> >
> > @Inject
> > Request _request;
> >
> > _request.getParameter("fieldName");
> >
> > You'll have to deal with the potential for strange values, null, etc.
> >
> > Although, if this is for your selection list problem from
> > earlier I believe a better solution might be to create a map
> > and use that as the model for your the t:select component.
> >
> > Create a property:
> > private HashMap<String, String> _schoolModel; private String
> > _schoolId;
> >
> > in setup render:
> >
> > for ( School school : getSchools() ) {
> >   String value = school.getName() + " - " + school.getLocation();
> >   String key = school.getId().toString();
> >   _schoolModel.put(key, value);
> > }
> >
> > in your template:
> >
> > School: <t:select t:id="schoolId" t:model="schoolModel"/>
> >
> > I haven't compiled this code, so there might be typos/bugs,
> > but that's the gist.
> >
> > Josh
> >
> >
> > On 10/12/07, Jean-Philippe Steinmetz <[EMAIL PROTECTED]> wrote:
> > >
> > > Hi all,
> > >
> > > So I have a form that has several elements. A few of the
> > elements are
> > > not done using the tapestry components and use regular HTML because
> > > the required steps to make things work as needed with the
> > components
> > > is simply not a suitable solution. So how do I get these
> > regular form
> > > elements to save properly?
> > >
> > > Jean-Philippe
> > >
> >
> >
> >
> > --
> > --
> > TheDailyTube.com. Sign up and get the best new videos on the
> > internet delivered fresh to your inbox.
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


-- 
Howard M. Lewis Ship
Partner and Senior Architect at Feature50

Creator Apache Tapestry and Apache HiveMind

Reply via email to