摘要: val在jquery中有两种用法,一种是直接获得第一个匹配元素的当前值。第二种是他也可以和attr一样设置每一个匹配元素的值。一种:来自jquery文档获得第一个匹配元素的当前值。在 jQuery 1.2 中,可以返回任意元素的值了。包括select。如果多选,将返回一个数组,其包含所选的值。Get the content of the value attribute of the first matched element.In jQuery 1.2, a value is now returned for all elements, including selects. For multi 阅读全文
posted @ 2012-02-19 10:06 一枚快乐滴海绵 阅读(330) 评论(0) 推荐(0) 编辑