为什么此链接在 Safari 上不起作用?当我点击Click here
它应该打开http://othersite.com
和http://mysite.com/profile
。问题是它只打开http://mysite.com/profile
,并没有为http://othersite.com
. 这个适用于 Chrome 和 firefox ..我怎样才能让它在 Safari 上运行?
html
<a target="_blank" onclick="redirect()" href="http://othersite.com">Click here</a>
javascript
function redirect(){
location.href = 'http://mysite.com/profile';
}