本文介绍了getAttributeNode()和getAttributeNodeNS()警告的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的页面打开正常但在FF中我不断收到警告

My page opens properly but in FF I'm continuously getting warning

[10:44:54.904] Use of getAttributeNode() is deprecated. Use getAttribute() instead. @ http://localhost/admin/?page=add#
[10:46:23.828] Use of getAttributeNodeNS() is deprecated. Use getAttributeNS() instead. @ http://localhost/admin/?page=add

顺便说一句,我正在使用CKeditor。什么意味着警告?以及如何解决它?

Btw i'm using CKeditor. What does mean that warning? and how to fix it?

推荐答案

这两种方法在Firefox 7中已弃用,因为它们已经,DOM规范的当前版本。最终它们很可能会从Firefox和其他浏览器中删除。

Those two methods are deprecated in Firefox 7 because they have been removed in DOM4, the current version of the DOM spec. It is likely that eventually they will be removed from Firefox and possibly other browsers.

如果警告来自CKEditor代码,我相信CKEditor团队会意识​​到这个并在某些时候发布不使用这些方法的更新。但是,我在CKEditor的源代码中找不到任何使用此方法的内容,因此更有可能来自您在页面上包含的其他内容。可能是CKFinder,似乎确实使用了这种方法?

If the warnings are coming from CKEditor code, I'm sure the CKEditor team will be aware of this and release an update at some point that does not use these methods. However, I couldn't find any use of this method in CKEditor's source code, so it's more likely to be coming from something else you're including on your page. Possibly CKFinder, which does seem to use that method?

这篇关于getAttributeNode()和getAttributeNodeNS()警告的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-01 11:29