A reader asked if she can make a navigation tab open more than one link when clicked. The answer is YES it can be done, with the help from a small Javascript. Occasionally we got such a situation that we need multiple links to be opened together. Say, you are an owner or author of a blog or website that supply different types of download e.g. movies, themes, software, wallpapers etc, your web page must contain a clickable link. You might like to add more than one link to be opened when visitor click on the link so that you can earn more (by affiliate/ linkbucks/adfly) or increase page views etc. In that case you can do this stuff with simple script. We need a little modification instead of our regular html code to make open more than one link when visitor’s click.
Not only the reason i describe above but also multiple links can be opened in a single click for various purpose. There might be several ways to open more than one link just a single click, i narrate 2 systems. See the example of open multiple web pages, in separate windows, with one mouse click.
Table of Contents
Features:
1.) Simple And Best Code.
2.) Quick To Load And Easy To Use.
3.) Cross Browser Compability.
4.) Pure HTML Code With DOM Event.
5.) Open Two Click From One Link.
6.) It Will Help You To Increase Pageviews.
7.) Little Hack To Increase Your Ads Clicks.
8.) SEO Supported.
9.) One Link In Same Tab And Other In New.
10.) No POPUP Will Open.
11.) Work With POPUP Blocker Also.
12.) InLine JavaScript Added.
How To Add In Blogspot?
1.) Go To Your www.blogger.com
2.) Open Your Desire “Blog“.
3.) Go To “Layout“.
4.) Click “Add A Gadget” Where You Want To Add It.
5.) Now Scroll To “HTML-JAVASCRIPT“
6.) Click “+” Icon To Add It.
7.) Now Copy The Below Code And Paste It To There.
8.) Click “Save“, Now You Are Done.
OR
1.) Go To Your www.blogger.com
2.) Open Your Desire “Blog”.
3.) Go To “Template“.
4.) Click “Edit HTML“.
5.) Now Click Within Code Box.
6.) Press [CTRL+F] To Search <body> Code.
7.) Now Copy The Below Code And Paste It Between “<body> </body>“.
8.) Click “Save Template” And Done.
OR
1.) Go To Your www.blogger.com
2.) Open Your Desire “Blog“.
3.) Create A “New Post” Or “Edit” Some One Existing.
4.) Click “Edit HTML” Tab In The Post Editor.
5.) Now Copy The Below Code And Paste It There
8.) Click “Publish” Or “Update” To Done.
How To Add In Website?
1.) Just Go To Your HTML File.
2.) Now Copy The Below Code And Paste It Between “<body> </body>“.
3.) Save It, Now You Are Done.
1.) Open One-Link In New Tab:
There are three type of code we have, the first one is simple as you know and it will be only apply of <a> tag whereas second one have the same function but can apply on any tags like <div, span, h1, h2, h3, p> etc. The third one is also same as second one but it just contain few chracters more to be playble in old browers.
<a href="https://www.exeideas.com" target="_blank">Open One Link New Tab</a>
<a onclick="window.open('https://www.exeideas.com');" >Open One Link New Tab</a>
<a onclick="window.open('https://www.exeideas.com','newwin');" >Open One Link New Tab</a>
2.) Open One-Link In Same Tab:
There are two type of code we have, the first one is simple as you know and it will be only apply of <a> tag whereas second one have the same function but can apply on any tags like <div, span, h1, h2, h3, p> etc.
<a href="https://www.exeideas.com" >Open One Link In Same Tab</a>
<a onclick="location.href='https://www.exeideas.com';" >Open Link In Same Tab</a>
3.) Open Two-Links:
This is a special code that will open your two links on one click in which one will be in same tab and othre will be in new tab and it will be only apply of <a> tag.
<a href="http://www.exedeas.com" onclick="location.href='https://www.exeideas.com';" target="_blank">Open Two Links With One Click</a>
Customization:
1.) Just Change Your URL In The Above Code.
2.) Change The Text Of Link Or Add Image Or Apply Anywhere.
3.) Save And Done…
again an awesome tips from you bro.you rockss.
Welcome Again And Thanks For Liking Our New Tip, Be With Us To Get More From Us…
Awesome Trick Bro 😉
But i want know how to open both links in new tab? how can we do with image or download button?
You Can Use Below Code As You Wish But One Link Will Be In POPUP That Every New Browser Can Hide This But Your WebPage Count A Views.
<a href=”http://www.exedeas.com” onclick=”window.open(‘https://www.exeideas.com’,’newwin’);” target=”_blank”>Open Two Links With One Click</a>
can u give code for board/forum usage…
i am unable to figure it out
Some Forum Blocked JavaScript So These Code Can’t Work Out There But Don’t Worry And Be With Us, We Will Find Other Solution Too In Upcoming Days…
Hello,
hey bro, its a awesome trick,
I have a wordpress amazon affiliate cart site, i want to use this on my Buy now button (new tab goes to Amazon, Present page go to Thank you page) Please help me to fix this Issue
Thanks in advance.
Regards,
Raakesh Vanaraj
You cant edit others widgets but you can edit yours in your blog. Share your blog URL so we will check…
very informative blog post. Thanks for sharing.
Welcome here and thanks for reading our article and sharing your view. This will be very helpful to us to let us motivate to provide you with more awesome and valuable content from a different mind. Thanks again.
I really liked the content which is very helpful for me. Thanks for sharing.
Welcome here and thanks for reading our article and sharing your view. This will be very helpful to us to let us motivate to provide you with more awesome and valuable content from a different mind. Thanks again.