Hi, experts:

How to assign a value to each choice in a checkbox, e.g. checkbox:apple;banana;pear. After I checked apple and pear, I can assign them values 1 and 3.Then these two values are sent to another jsp page, so that I can use the values in the new jsp page.

jeff

two ways(of many)

<form <!--etc-->>
<input type='checkbox' name='check0' value='apple'>apple<br>
<input type='checkbox' name='check1' value='banana'>banana<br>
<input type='checkbox' name='check2' value='orange'>orange<br>

<input type='checkbox' name='bannana' value='yes'>banana<br>
<input type='checkbox' name='orange' value='yes'>orange<br>
<input type='checkbox' name='apple' value='yes'>apple<br>

<input type='submit' onclick="return(confirm('sure?'));">
</form>
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.