Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

How to open specific link in new tab on pageload

Many people on the web, search for How to open a specific link in a new tab on page load or How to open links in a new tab on click. Some of them also want to open their own site on a page. So we are sharing the most used scripts for opening a link in the new tab.

How to open a specific link in a new tab on page load

There are scripts that you can use on your site or on any single page to open a link in a new tab on page load.
  • Open a link in the same tab on Page-Load
  • Open a link in New Tab on page-load
body onload="window.open('https://www.abhishekindora.com/', '_blank');">
  • Open or auto-refresh different URL in New Tab By using the meta tag.
meta http-equiv="refresh" content="5;URL=javascript:window.open('https://www.abhishekindora.com/', '_blank');" />

How to open links in a new tab on click

There are scripts that you can use on your site or on any single page to open the link when the user clicks anywhere.
  • Add a single link to open when only clicking on the link
Abhishek Indora
  • Open URL on click anywhere in new tab
body onclick="window.open('https://www.abhishekindora.com/', '_blank');">

How To Auto-Refresh The URL By Meta tag

You can use these scripts if you want to automatically refresh the URL.
  • Refresh the same URL by using the meta tag.
meta http-equiv="refresh" content="5" />
  • Refresh a different URL after 10 seconds
meta http-equiv="refresh" content="10;URL='https://www.abhishekindora.com/'" />


This post first appeared on Abhishek Indora, please read the originial post: here

Share the post

How to open specific link in new tab on pageload

×

Subscribe to Abhishek Indora

Get updates delivered right to your inbox!

Thank you for your subscription

×