Which browsers support document.activeElement?

可紊 提交于 2019-12-17 16:24:09

问题


Which web browsers / versions have support for document.activeElement?

This property lets you see which element is active / has focus.

Are there any main gotchas/difference between implementations?


回答1:


document.activeElement is supported by IE6+, FF3+, Safari 4+, Opera 9+, Chrome 9+. (FF2, Saf3 don't support this property)




回答2:


It still doesn't work on WebKit based browsers in xhtml page see https://bugs.webkit.org/show_bug.cgi?id=63922



来源:https://stackoverflow.com/questions/5318415/which-browsers-support-document-activeelement

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!