tax_popup (interchange-5.8.2) | : | tax_popup (interchange-5.10.0) | ||
---|---|---|---|---|
[if config SalesTax ne multi] | [if config SalesTax ne multi] | |||
<script> // JavaScript Form Validation Demo // by Paul Colton | <script> | |||
function check_tax(form) { | function check_tax(form) { | |||
// Make sure the email field is not blank | ||||
var foundState = false; | var foundState = false; | |||
[calc] | [calc] | |||
if($Variable->{TAXCOUNTRY}) { | if($Variable->{TAXCOUNTRY}) { | |||
return q{var ch = 'NEVAIRBE';} | return q{var ch = 'NEVAIRBE';} | |||
unless $Variable->{TAXCOUNTRY} =~ /\b$Val ues->{country}\b/; | unless $Variable->{TAXCOUNTRY} =~ /\b$Val ues->{country}\b/; | |||
} | } | |||
return q{var ch = form.state.value;} | return q{var ch = form.state.value;} | |||
[/calc] | [/calc] | |||
ch = ch.toUpperCase(); | ch = ch.toUpperCase(); | |||
[loop list="__TAXAREA__"] | [loop list="__TAXAREA__"] | |||
if(ch == "[loop-code]") { | if(ch == "[loop-code]") { | |||
alert("You will be charged [currency][fly-tax [loop-code]][/currency ] sales tax\nsince you are shipping to [loop-code]. Click Recalculate to see the amount in your total."); | alert("You will be charged [currency][fly-tax [loop-code]][/currency ] sales tax since you are shipping to [loop-code]."); | |||
foundState = true; | foundState = true; | |||
} | } | |||
[/loop] | [/loop] | |||
return foundState; | return foundState; | |||
} | } | |||
</script> | </script> | |||
[/if] | [/if] | |||
End of changes. 4 change blocks. | ||||
4 lines changed or deleted | 3 lines changed or added |