jquery常见用法
- $(a,b)
a:用来查找的字符串
b:用来查找的范围(上下文)
例:$("input:radio", document.forms[0]) 在文档的第一个表单中,查找所有的单选按钮(即: type 值为 radio 的 input 元素)。
- $(attribute,value)
例:$("input[name='newsletter']").attr("checked", true);
$("input[name!='newsletter']").attr("checked", true);
- $(a).hide(),$(a).show()