javascript - Jquery: wait till open in new tab is selected and then redirect -
i have html element looks this.
<a href="#" id ="bs">buildsummary</a>
i need to display pop window on clicking link. if right click , click on 'open in new tab' should open new tab , new tab opened should have same data pop window contains.
in event handler, have used 1 if block handle right click shown below.
$(document).on("click contextmenu",'#bs',tabeventhandler) function tabeventhandler(event){ event.preventdefault(); if( event.which == 3 ){ var wnd = window.open("about:blank","_blank"); wnd.document.write(ajaxresult); } }
but opens new tab son right click on link. want browser display menu , after user selects 'open in new tab' should open new tab. how can achieve this?
Comments
Post a Comment