Text input for multi-valued attribute
- by Sean
I need to create an input form that will allow a user to enter any number of values for a particular attribute.
I've tried several approaches, all of which seem to have various levels of failure. The latest model bean looks something like:
public class Product {
private String name;
private String[] tags;
...accessors...
}
The input fields look something like:
<h:inputText id="name" value="#{product.name}"></h:inputText>
<h:inputText id="tag0" value="#{product.tag[0]}"></h:inputText>
My plan was to allow the user is to use javascript to add additional form fields as needed.
This type of setup gives me a 'Target Unreachable' error. What am I missing?
I am using JSF 1.1 on WebSphere 6.1