I have a page with a number of checkboxes. Each Checkbox is for a different item (virtual Rose) and rose has a different value. I have put the value of the rose into the value="" of the checkbox. I need to add up the total value of the ticked checkboxes - eg: 100, 230 etc. The only other factor is I need to only add up checkboxes with the class "giftsRosesCheckBox".
<table id="tableGiftsWhiteRose"><tr>
<td colspan="2">White Rose</td></tr><tr>
<td><input type="checkbox" class="giftsRosesCheckBox" value="100"/></td>
<td class="credits">100 credits</td>
</tr></table>
<table id="tableGiftsRedRose"><tr>
<td colspan="2">Red Rose</td></tr><tr>
<td><input type="checkbox" class="giftsRosesCheckBox" value="130"/></td>
<td class="credits">130 credits</td>
</tr></table>
<table><tr>
<td colspan="2">Stunning Red Rose</td></tr><tr>
<td><input type="checkbox" class="giftsRosesCheckBox" value="150"/></td>
<td class="credits">150 credits</td>
</tr></table>
I'm really not sure how to do this so a push in the right direction would be great.
thanks so much.