Given the code on the page?
<div class="block"> <input type="checkbox" value="1" name="one"> <input type="checkbox" value="2" name="two"> <input type="checkbox" value="3" name="three"> <input type="checkbox" value="4" name="four"> </div> How can I make calculations and get the sum of value (answer 10) and know how many checkboxes at the same time selected the whole (in this case 4). The name of the field is not important, you can make all the name = "box []"