I have 3 radio buttons
<input type="radio" name="preferedpaymt" value="CheckMailed" id="CheckMailed1" <?php if($paymnt=="CheckMail") {?> checked="checked" <?php }?> />
(a)Check Mailed
<input type="radio" name="preferedpaymt" value="PayPal" <?php if($paymnt=="PayPal") {?> checked="checked" <?php }?> />
(b)By PayPal
<input type="radio" name="preferedpaymt" value="WireTransfer" id="WireTransfer" <?php if($paymnt=="wireTransfer") {?> checked="checked" <?php }?> />
(c)Wire Transfer To Bank A/c$12
But the value of radiobutton is checked from database . With these 2 tables are associated if Radiobutton 2 is checked table1 1 should populate id tb1
here the problem is when a value of radio button is checked from database the table does not get populate if you only click it gets populated i want it automatis how can i do it?
jquery code, which I am using
<script type="text/javascript">
jQuery(function () {
jQuery("input[name=preferedpaymt]").change(function () {
if ($(this).val() == "PayPal") {
jQuery("#ppl").slideDown()
} else {
jQuery("#ppl").slideUp();
}
});
});
</script>