How to add a custom right-click menu to a webpage?

后端 未结 19 1213
广开言路
广开言路 2020-11-22 15:54

I want to add a custom right-click menu to my web application. Can this be done without using any pre-built libraries? If so, how to display a simple custom right-click menu

19条回答
  •  南笙
    南笙 (楼主)
    2020-11-22 16:35

    You should remember if you want to use the Firefox only solution, if you want to add it to the whole document you should add contextmenu="mymenu" to the tag not to the body tag.
    You should pay attention to this.

提交回复
热议问题