开发者

Radio button value

I have a dynamically generated radio button as fiven below

echo '<tr>
                            <td colspan="2">Login System</td>
                  开发者_StackOverflow          <td colpan="2">
                                <input type="radio" name="login_system'.$i.'" value="COMMON" checked="checked" />Common &nbsp
                                 <input type="radio" name="login_system'.$i.'" value="INDIVIDUAL">Individual
                            </td>
                        </tr>';

and i need to take its value using javascript. Below is the code i have written for that

d['login_system']=$('input[name="login_system'+index+'"]').val();

But always I am getting value of first radio button even if I have selected second. Can anyone help me?


$('input[name="login_system'+index+'"]:checked').val()

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜