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

后端 未结 19 1532
广开言路
广开言路 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条回答
  •  萌比男神i
    2020-11-22 16:15

    
    
    
    
    
      

    I like chocolate


    I AM AWESOME

    Right click to get sweet results!

    You can tweak and modify this code to make a better looking, more efficient contextmenu. As for modifying an existing contextmenu, I'm not sure how to do that... Check out this fiddle for an organized point of view. Also, try clicking the items in my contextmenu. They should alert you a few awesome messages. If they don't work, try something more... complex.

提交回复
热议问题