# 彥彰救星 ```javascript $(document).ready(function() { let sendPrice = $('#sendPrice').val(); $('.discount-checkbox').click(function() { let checkBoxPrice = 0; $("input[name='buyPackageDiscount']:checked").parents("li").find(".discount-plans-dropdown").each(function(i, element) { let priceForAdd = parseInt(element.dataset.foradd) console.log("==========priceForAdd:" + priceForAdd); checkBoxPrice += priceForAdd console.log("總結1:" + checkBoxPrice); }) console.log("總結2:" + checkBoxPrice); }); }); ```
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up