I'm using jQuery Context Menu plugin.
I have the following:
$('div').contextMenu({
menu: 'menu'
},function(action, el, pos) {
//some statements
});
How to activate it when a user 'click' instead of just right click?
I'm using jQuery Context Menu plugin.
I have the following:
$('div').contextMenu({
menu: 'menu'
},function(action, el, pos) {
//some statements
});
How to activate it when a user 'click' instead of just right click?
LOL
I was going to say: change plugin code, line 40
if( evt.button == 1 ) {
to
if( true ) {
evt.button == 2 instead.$('div').click(function(){
$("").contextMenu({
menu: 'menu'
},function(action, el, pos) {
//some statements
});
});
this should work fine
context menu when div is clickedclicked, it just assigned the context menu when clicked.