Thanks Gabriel and Jeromy,

I had thought of iterating through the List but was trying to avoid
generating a mass of HTML hidden fields.

I like it how the hidden tag translates the List into a meaningful
String, it's just a shame that Struts/XWork doesn't handle it when the
form is submitted.

I have raised an Improvement request on the JIRA
(https://issues.apache.org/struts/browse/WW-2612) and will continue to
investigate a way around this.  If anyone else has some bright ideas
it would be more than welcome.

Regards,
Steve

On Wed, Apr 23, 2008 at 10:57 PM, Jeromy Evans
<[EMAIL PROTECTED]> wrote:
>
> Steve Akins wrote:
>
> > I have a List called "ids" which contains 4 Strings "22030", "6496",
> > "6457", "6448"
> >
> > When the following tag is used:
> > <s:hidden name="resend.ids" />
> >
> > It produces the following HTML:
> >
> > <input type="hidden" name="resend.ids" value="[22030, 6496, 6457,
> > 6448]" id="/test/resend_resend_ids"/>
> >
> >
> > When the form is submitted the "ids" List is populated with one String
> > "[22030, 6496, 6457, 6448]" instead of 4 Strings "22030", "6496",
> > "6457", "6448".
> >
> >
> > This looks like a problem with how the XWorkBasicConverter is working
> > or I have just not figured out how to do this yet.
> >
> > I would have thought that there's support for passing a List through a
> > form without the need for creating a custom converter for this.
> >
> > Does anyone have any ideas on how to overcome this problem?
> >
> >
> > Regards,
> > Steve
> >
> >
> >
>  Hi Steve,
>
>  I've seen this before but didn't have time to investigate.  I just split
> the string into an array in my action.
>  I agree it should work as you've described without a custom converter. But
> doesn't. Or doesn't always. Or doesn't give enough feedback about why it
> didn't.  If you have time, it would be helpful if you can see if an issue
> exists in JIRA and if not create one.
>
>  regards,
>  Jeromy Evans
>
>
>
>
>  ---------------------------------------------------------------------
>  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