<a> element with, javascript:window.open, works in desktop browser but not in mobile browser

时间:2015-12-29 04:28:25

标签: javascript html window.open

The following code snippet is designed to close the browser tab when the <a> element is clicked. This works in a desktop browser (Chrome), but not in a mobile browser (Chrome on iPhone). Why?

<a href="javascript:window.open('','_self').close();" title="close this profile"> 
    <img src="images/closetab.png"
        style="height:70px;width:70px;position:absolute;right:0;top:0" />
</a>

0 个答案:

没有答案