Is there a way to show "Open Link in New Tab", and "Open Link in New Window" etc.. by right-clicking on a div tag as same as an "a" tag with href attribute?
答案 0 :(得分:0)
您可能可以使用JavaScript提供自定义的右键菜单:
el.addEventListener('contextmenu', function(ev) {
ev.preventDefault();
alert('Custom menu !');
return false;
}, false);