FULL STACK   ·   UI   ·   UX   ·   GRAPHICS   ·   DEVELOPER   ·   INSTRUCTOR

Adam Khoury

Donate funds to show love and support

Click the button below to donate funds securely online. You can use your PayPal account or a credit card.

Your donations help free up my time to produce more content and assist in covering server costs. It's also a great way to say thanks for the content!

Application Configuration

Adam will be adding options here soon.

JavaScript How to Calculate Tax Rates into Prices

Published :
Author :
Adam Khoury

Learn to calculate tax rates into prices using JavaScript.

<script> let gstRate = 5; let pstRate = 10; let roomprice = 100; let totalwithgst = roomprice * (1 + gstRate / 100); let totalwithpst = roomprice * (1 + pstRate / 100); let totalfixedgst = totalwithgst.toFixed(2); let totalfixedpst = totalwithpst.toFixed(2); alert( totalwithgst + " | " + totalwithpst ); alert( totalfixedgst + " | " + totalfixedpst ); </script>