You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Alex Colic <al...@pop-ware.com> on 2001/04/26 17:49:24 UTC

How to have two tags populate one field?

Hi,

I have a bit of a problem. I have a select box and a text box which I need
to both point to one property.

The combo has a list of titles. The user could select one of these titles or
input there own but when they submit the box I need the following to occur:

If there is text in the text box then that is the title else
the option selected is the title.

Could this be done within Struts?



Regards

Alex Colic, HBA, B. Ed
PopWare Inc. "Driving down the cost of conversions!"
E-Mail: Alex.Colic@pop-ware.com
Tel: 1-905-777-8171 ext. 104
Fax: 1-905-777-0132


Re: How to have two tags populate one field?

Posted by Peter Alfors <pe...@irista.com>.
I would place the logic of which field to use in your action class that is
submitting the request.

Pete

Alex Colic wrote:

> Hi,
>
> I have a bit of a problem. I have a select box and a text box which I need
> to both point to one property.
>
> The combo has a list of titles. The user could select one of these titles or
> input there own but when they submit the box I need the following to occur:
>
> If there is text in the text box then that is the title else
> the option selected is the title.
>
> Could this be done within Struts?
>
> Regards
>
> Alex Colic, HBA, B. Ed
> PopWare Inc. "Driving down the cost of conversions!"
> E-Mail: Alex.Colic@pop-ware.com
> Tel: 1-905-777-8171 ext. 104
> Fax: 1-905-777-0132