Re: Form with Multiple selections

>  
> Hi,
> 
> I was trying to have a html form with multiple entries in a drop down box.
> 
> ex:
> <select multiple name="favcolor" size = 3>
>      <option>green
>      <option>aquamarine
>      <option selected>emerald
>      <option>turquoise
>      <option>aqua
>      <option>black
>      <option>yellow
>      </select>
> 
> Does any one know how I could use URLDecoder class ( data.getValue("string")) 
> here. Or do i have to write sth on my own for this. 
> 
> Basically I know in forms everything works as a name value pair but when we use
> the 'multiple' option in the select tag , I am not sure how things work.
> Is one name associated with all these multiple values that the user selects ?
> Does it mean that I have to call URLDecoder.getValue("favcolor") multiple number
> of times ? 
> Or is there another way to extract these values....
> 
> Would appreciate some help here.
> 
> Cheers !!!
>    Nirmal
>    npatil@ee.tamu.edu
> 
> 

 You can use data.getMultipleValues("blah");

 public String[] getMultipleValues (String name) in URLDecoder.java

 You just have to set the overide flag to false in the constructor :

 public URLDecoder (InputStream in, boolean overide)

 benoit.

 

Received on Thursday, 17 July 1997 07:54:26 UTC