Guest User

Untitled

a guest
Jan 16th, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.06 KB | None | 0 0
  1. <div class="header">
  2. <h3 class="checkout-headers">STEP 3 - Billing Information </h3>
  3. <!--START: sameAsBilling1-->
  4. <!--value="ON"-->
  5. <div class="sameAsBilling1">
  6. <input type="checkbox" name="sameAsBilling" id="sameAsBilling" value="1" onclick="showHideShipping();check_address('');"/>
  7. <label for="sameAsBilling">Same as Delivery Address</label>
  8. <div class="clear"></div>
  9. </div>
  10. <div class="differentBilling">
  11. <input type="checkbox" class="example" id="check2" value="2" onclick="myFunction2()"; return false;>Different Billing Address?</div>
  12. <!--END: sameAsBilling1-->
  13. <div class="clear"></div>
  14. </div>
  15.  
  16. <script>
  17. var chk1 = document.getElementById("sameAsBilling");
  18. var chk2 = document.getElementById("check2");
  19.  
  20. //check the other box
  21. chk1.on('click', function(){
  22. if( chk1.is(':checked') ) {
  23. chk2.attr('checked', true);
  24. } else {
  25. chk2.attr('checked', false);
  26. }
  27. });
  28. </script>
  29.  
  30. Uncaught TypeError: chk1.on is not a function
Add Comment
Please, Sign In to add comment