Fancybox on radio button
how to open fancybox on radio button checked
1 Answer
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Neeraj KumarRank #355 · 7K reputationPosted Jun 6, 2015, 9:10 AM EDT
id="testForm" method="post" action=""> A type="radio" name="shipping" value="A" /> /> B type="radio" name="shipping" value="B" /> /> type="image" id="shipping"/>$("#testForm").bind("submit", function(){ var shipping = $(this).find("input[type='radio']:checked").val(); if(shipping == "B") { $.fancybox({ 'content': 'you selected B', 'hideOnContentClick': false }); // fancybox } // if return false; // prevents the form to be submitted }); // bind