Do any browsers support HTML5's context menu?

馋奶兔 提交于 2019-12-09 02:29:59

问题


Do any browsers support the HTML5 context menu attribute?


回答1:


This has been added to Firefox 8.

See this for an example of it working https://bug617528.bugzilla.mozilla.org/attachment.cgi?id=554309




回答2:


Right now, the contextmenu attribute is not supported by any browser version. According to caniuse.com it doesn't have support for any current browser versions (IE 9, Firefox 4, Safari 5, Chrome 11, Opera 11.1, or any mobile browsers - iOS, Opera, or Android). It is unknown if it will be supported in future versions.

It was discussed in April 2010 regarding adding it to Webkit. But it doesn't look like it's been added to the nightlies yet.




回答3:


According to this wiki page for now there is no any popular layout engine except Firefox's Gecko that fully supports the menu element. Meanwhile, you can try some script solutions, like jQuery Context Menu Plugin.




回答4:


You can use Modernizr for HTML5 feature detection.




回答5:


It is working well here with Firefox 9.




回答6:


Firefox 8 Aurora implements this feature. But unfortunately it doesn't seem to work for me now...




回答7:


Pretty sure it's supported with a polyfill: https://github.com/medialize/jQuery-contextMenu



来源:https://stackoverflow.com/questions/4120588/do-any-browsers-support-html5s-context-menu

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