You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@turbine.apache.org by Jürgen Hoffmann <jh...@byteaction.de> on 2004/09/24 09:11:37 UTC

Re: Intake - check dynamically generated forms

Hi,

why not use one name for this field and make it multivalued? If this
number is one sort of database id then use a hidden field wit name id,
make this field multivalued, and then iterate over the corresponding
array.

Kind regards

Jürgen Hoffmann

Am Do, den 23.09.2004 schrieb fishfang@gmx.de um 22:58:

> Hi,
> 
> ok, I want to validate some dynamically generated forms with intake. My
> problem is that the actual number of input fields depends on the user and
> can change every time the form is loaded, so it is not possible to match
> every field with an entry in intake.xml. The names of the input-fields all
> start with the same identifier, but end with an unique id. I thought that I
> can cut of this id in some way and than check the fields using intake. Is
> this possible? My problem is that I can't figure out when exactly the data
> from the form is passed to intake.
> 
> Thx Andreas
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org
> 
> 
> !EXCUBATOR:4153292c255596545359466!




AW: Intake - check dynamically generated forms

Posted by Andreas Schwersenz <fi...@gmx.de>.
Hi,

thanks for your answer, but I still got a question.
Ok, I can do something like this:

<field name="hola" multiValued="true" key="TemplateNameKey" type="String">
...
</field>

And in my template:

...
<input name="$testgroup.hola.Key" value="$!testgroup.hola" size="25"
type="text">
<input name="$ testgroup.hola.Key" value="$!testgroup.hola" size="25"
type="text">
...

But I need to match every one of these input fields with an id. 
Did you mean something like this:

...
<input name="$testgroup.hola.Key" value="$!testgroup.hola" size="25"
type="text">
<input name="$testgroup.hola.Key" value="id_1" size="25" type="hidden">
<input name="$ testgroup.hola.Key" value="$!testgroup.hola" size="25"
type="text">
<input name="$testgroup.hola.Key" value="id_2" size="25" type="hidden">
...

But this is not a very nice way, I think, as it is not really matching the
fields via some name.

Thy Andreas

> -----Ursprüngliche Nachricht-----
> Von: Jürgen Hoffmann [mailto:jh@byteaction.de]
> Gesendet: Freitag, 24. September 2004 09:12
> An: Turbine Users List
> Betreff: Re: Intake - check dynamically generated forms
> 
> Hi,
> 
> why not use one name for this field and make it multivalued? If this
> number is one sort of database id then use a hidden field wit name id,
> make this field multivalued, and then iterate over the corresponding
> array.
> 
> Kind regards
> 
> Jürgen Hoffmann
> 
> Am Do, den 23.09.2004 schrieb fishfang@gmx.de um 22:58:
> 
> > Hi,
> >
> > ok, I want to validate some dynamically generated forms with intake. My
> > problem is that the actual number of input fields depends on the user
> and
> > can change every time the form is loaded, so it is not possible to match
> > every field with an entry in intake.xml. The names of the input-fields
> all
> > start with the same identifier, but end with an unique id. I thought
> that I
> > can cut of this id in some way and than check the fields using intake.
> Is
> > this possible? My problem is that I can't figure out when exactly the
> data
> > from the form is passed to intake.
> >
> > Thx Andreas
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: turbine-user-help@jakarta.apache.org
> >
> >
> > !EXCUBATOR:4153292c255596545359466!
> 
> 




---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org