Opening Link to a New Tab |
Opening Link to a New Tab |
Animation Sigmabear |
May 10 2021, 12:12 AM
Post
#1
|
Group: Members Posts: 2 Joined: 9-May 21 Member No.: 27,933 |
Hi guys, I am new to the forum
I am stuck with a certain part of our website and found this place looking for answers. So my plan is quite simple, I need to click a link and it should open a new browser tab instead of loading it on the main tab. I have watched multiple tutorials on Youtube. The code is very simple and it works. I applied it to my code: CODE <a onclick="window.open(location.href='vrdemo/vrdemohouse.html',target='_blank')">VR 360 tab test</a> <a onclick="location.href='vrdemo/vrdemohouse.html'">VR 360</a> 1st link is the new test link. 2nd is the old one, where clicking it will load the page on the current tab. The problem I have with the first one is, when I click, it opens a new tab BUT ALSO loads the page on the current. What am I getting wrong here? The code and tutorials are so simple and straight forward I am lost at what I got wrong. |
Lo-Fi Version | Time is now: 26th April 2024 - 05:17 PM |