Doing math on variable if box is checked...
Hi all, this is my first post here (I think) so I hope I'm in the right area, basically I've wrote a form for a club I'm involved in and I'm trying to add the paypal fees (
3.4% + 20p ) to a variable if 'pay by paypal' is checked, this is the jquery bit, I've put the bits I'm interested in, into a JSFiddle
Thanks in advance
- $('.items').click (function () {
- if ($(this).val() == "champcomp" || $(this).val() == "competitor" ) {
- var value = "30.00"; } else { var value = "0.00"; }
- $('#hidd_item1') .val(value);
- });