You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by a k <st...@gmail.com> on 2006/10/02 19:18:25 UTC
Changing the label for f:selectItem
Hi,
I am using f:selectItem to display the options for a radio button field. But
I have a requirement where I need to change the label of one of the options
dynamically. I am trying to accomplish this using client-side javascript w/o
making a round-trip to the server. Is this possible with f:selectItem? Are
there any components that give me the functionality that I am looking for?
Thanks!
Re: Changing the label for f:selectItem
Posted by Gerald Müllan <bi...@gmail.com>.
Hi,
f:selectItems with binding the value to a corresponding getter (where
changing the item labels) after doing a submit should do the thing.
You can accomplish the submit by fireing an onchange event on client
side like this (component`s attribute):
onchange="this.form.submit()"
regards,
Gerald
On 10/2/06, a k <st...@gmail.com> wrote:
> Hi,
>
> I am using f:selectItem to display the options for a radio button field. But
> I have a requirement where I need to change the label of one of the options
> dynamically. I am trying to accomplish this using client-side javascript w/o
> making a round-trip to the server. Is this possible with f:selectItem? Are
> there any components that give me the functionality that I am looking for?
>
> Thanks!
>
>
--
http://www.irian.at
Your JSF powerhouse -
JSF Consulting, Development and
Courses in English and German
Professional Support for Apache MyFaces