Opennig a select menu with jquery on right mouse click

64 views Asked by At

So I'm confronted with a bit of a problem. I want to display a custom select menu when a user right clicks inside.

So I don't even know how to approach this problem because once the select is open if user chooses option 1 the value will be inputted into the text area.

I understand that I have to run the select code if mouseclick() == 3; further than that, how would i go about this?

Thanks for the help in advance.

Much love.

1

There are 1 answers

0
Travis Pettry On BEST ANSWER

If all you want to do is stop the context menu from displaying do the following:
When the user click the page with the right click the context menu event is invoked. If you want to disable that see this fiddle: http://jsfiddle.net/4gk7zv9z/

In this fiddle when the contextmenu event is invoked the JS code prevents it from displaying the context menu and allows the programmer to do what ever he or she likes.