Beginners question about adding variables to a function:
Putting in the amounts :
var calcdiscount = function () {
var test = $('#discount').val();
if (test.length > 0 && $('#discount')[0].checkValidity()) {
PizzaSizeCost(2);
}
else {
PizzaSizeCost(0);
}
}
;
Getting out the amount:
var PizzaSizeCost = function (test) {
How can I do this ?
How can I do this ?Do what?