带有jquery句柄的单选按钮语法

时间:2011-11-16 08:23:55

标签: javascript jquery html css

如何使用等式语法javascript jquery来实现这种语法:

document.getElementById ("tone_positive_" + x). checked = true

我试过但失败的一些例子,或者我不明白应对jquery的单选按钮,谢谢,

1 个答案:

答案 0 :(得分:2)

$("#tone_positive_" + x).attr("checked", "checked");

工作?