How To Make A Link Open In New Tab As Well As Redirect In Current
So, I need to make it so if the user is on mysite.com/cat and they click something, then in the mysite.com/cat tab, they are redirected to mysite.com/dog AND a link is opened in a
Solution 1:
<ahref="#"target="_self"onclick="RedirectUrl()">Click</a><script>functionRedirectUrl(){
window.location.href ="yourUrl";
}
<script>
Solution 2:
You can do
<a href="dog.html" target="_blank" onclick="window.location.href ="dog.html";">Click</a>
Post a Comment for "How To Make A Link Open In New Tab As Well As Redirect In Current"