You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Qasim Khawaja <Qa...@admin.ox.ac.uk> on 2003/07/14 12:58:11 UTC

DynaActionForm

How do you populate Drop down lists in a DynaActionForm?

Q




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


Re: A dynamic _map_ (not list) index?

Posted by Martin Naskovski <mn...@san.rr.com>.
Never mind this question, I answered it to myself. The EL works just as
well on map backed forms as it does on list-backed forms, or list backed
form properties, more correctly :).

Sorry to bug anyone.
Martin

Tuesday, July 15, 2003, 9:34:16 AM, you wrote:

MN> I was looking at http://jakarta.apache.org/struts/faqs/indexedprops.html,
MN> and realized it's possible to get a dynamic arraylist index by using
MN> Struts-EL.  Well, my question is, if I have a radio button like:

MN> <logic:iterate id="element"....>
MN> <html:radio property='userSkill' value="value(somekey)"/>
MN> </logic:iterate>


MN> Can I _still_ use Struts-EL inside the value="" attribute to generate a
MN> dynamic key based off some exposed iterator (e.g. "element" from above),
MN> which is indeed a String value?

MN> What's a way to do this? It isn't quite the same as an index for a list,
MN> it's not a number, and there's no concrete example for a dynamic map index,
MN> which is why I ask.

MN> Can someone clue me in? I'm sort of stuck :).

MN> Thank you.
MN> Martin


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


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


A dynamic _map_ (not list) index?

Posted by Martin Naskovski <mn...@san.rr.com>.
I was looking at http://jakarta.apache.org/struts/faqs/indexedprops.html,
and realized it's possible to get a dynamic arraylist index by using
Struts-EL.  Well, my question is, if I have a radio button like:

<logic:iterate id="element"....>
<html:radio property='userSkill' value="value(somekey)"/>
</logic:iterate>


Can I _still_ use Struts-EL inside the value="" attribute to generate a
dynamic key based off some exposed iterator (e.g. "element" from above),
which is indeed a String value?

What's a way to do this? It isn't quite the same as an index for a list,
it's not a number, and there's no concrete example for a dynamic map index,
which is why I ask.

Can someone clue me in? I'm sort of stuck :).

Thank you.
Martin


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


Re: DynaActionForm

Posted by Dichotomy <di...@greenmail.ch>.
The same way as any other action-form?

In short, you build an <html:select> with an <html:options> tag inside, giving the collection containing the options as a parameter to html:options...

-- 
If education is too expensive, try ignorance.

On Mon, 14 Jul 2003 11:58:11 +0100
Qasim Khawaja <Qa...@admin.ox.ac.uk> wrote:

> How do you populate Drop down lists in a DynaActionForm?
> 
> Q
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: struts-user-help@jakarta.apache.org
> 

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