jqueryFirefox3.5中操作select的问题_jquery
                        
                            时间:2021-07-01 10:21:17
                            帮助过:6人阅读
							                        
                     
                    
                    页面中有一个select元素,id为customer,在网上好多的介绍jquery引用select的选中值的方法都是用: 
 代码如下:
$("#customer option[selected]").val(); 
这个方法来得到selcte选中项的值。我也是一直是这么用,不过最近安装了FF3.5正式版,发现这种方法在它下面得不到值,就去看jquery的帮助文档,在文档中对select选中的引用是用如下方法: 
 代码如下:
$("#customer option:selected").val(); 
用这种方法引用在FF3.5下就正常了。