gpt4 book ai didi

jquery - 使用 jquery 确定所选选项会导致 "specified attribute is deprecated"警告

转载 作者:行者123 更新时间:2023-12-03 21:34:57 26 4
gpt4 key购买 nike

可能遗漏了一些非常明显的东西,但我不知道发生了什么。我正在尝试使用 jquery 来确定下拉列表中当前选定的选项 ( See fiddle ),但是当我执行如下操作时,我在 (FF9) 控制台中收到警告。

var selectedValue=$('#testSelect option:selected').val();

警告消息:

Warning: Use of attributes' specified attribute is deprecated. It always returns true.

我做错了什么吗?这是我应该关心的事情吗?提前致谢。

最佳答案

jquery 正在引用 Attr 对象上的“指定”属性,这在 Firefox 7 中已被弃用,并且始终返回 true。请参阅https://developer.mozilla.org/En/DOM/Attr

我为此提出了一张 jquery 票证:http://bugs.jquery.com/ticket/11397

关于jquery - 使用 jquery 确定所选选项会导致 "specified attribute is deprecated"警告,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8389841/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com