0

I want hide and show custom message on radio button selection of shipping method on checkout page , but jQuery is not working in that section due to knockoutjs. Anyone have any idea for that how to implement custom jquery on shipping method selection?

here is my jquery code :

 <script type="text/javascript">
 require(["jquery"], function($) {
 jQuery(document).ready(function(){
 jQuery('.radio').click(function() {
 alert("selected shipping");
 });
 });
 });
</script>
asked Oct 31, 2018 at 10:37

1 Answer 1

3
<script type="text/javascript">
 require(["jquery"], function($) {
 $(document).ready(function(){
 $(document).on("click", '.radio', function () {
 alert("selected shipping");
 }); 
 });
 });
</script>

Try this...!

answered Oct 31, 2018 at 10:56
1
  • your most welcome...! Commented Oct 31, 2018 at 13:51

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.