You need to use the name attribute:
window.open("https://www.youraddress.com","_self")
Edit: Url should be prepended with protocol. Without it tries to open relative url. Tested in Chrome 59, Firefox 54 and IE 11.
Answer from vdbuilder on Stack OverflowHow to make Edge to open links on the same tab by default
How to make links open in same tab? - Google Chrome Community
Opening the same Tab if its already opened by clicking the same link | OutSystems
Open new tab instead of new window
Videos
Hi I've found how to solve this issue
the problem is from Bing (the search engine) not Edge (Browser)
- Search Something on Bing
- Tap the 3-dash button setting on the upper right corner
- open safety search
- in safety search, turn off open new tab after link click
- make sure you save the setting
I'm changing my default browser away from Edge. The new tab for every link feature is just too annoying. And there doesn't appear to be a fix.
Thanks for reply. None of those options worked. The problem is 50/50, some hyperlinks it works find, others hyperlinks it doesn't.
- Right clicking option is disabled (greyed out).
- Holding CTRL doesn't work either. It still opens it in a new browser window
- The problem seems to depend on the hyperlink.
- I ran the powershell option on a test PC and nothing changed.
- I know there is a way to fix this because my PC (profile) works just fine. I have a few other staff that work fine. But anytime I hire a new person or they log into the PC profile of their own, it reverts back to opening up links in a new window.
Chrome has a simple option that says (open links in a new tab), is there no simple setting option in edge? My company I'm contracted with requires us to use edge.
Hi JDSuser, welcome to the Microsoft community, my name is Bruno Leonel.
We will be happy to help and see if we can resolve this issue for you. Follow some of the recommended suggestions below that have helped others.
I understand that you are having problems opening links in a new tab and I will try to help you in the best way.
There are some possibilities to open a link in the same tab see below:
In Microsoft Edge, you can open a link in a new tab, just right-click on the link and then choose “Open in a new tab”
You can also use the Ctrl key (press it and keep it pressed) and click with the left mouse button and the link will open in a new tab.
NOTE: If the links that are opening in a new window are from the google search site
At the bottom of the page click settings -> search settings
And confirm that the following option is checked: "Open each selected result in a new browser window"
Give it a try, if it doesn't work, check the steps below:
To try to resolve it, follow the steps below:
step 1
With Microsoft Edge open press Alt+F;
Click "Settings" / "Reset Settings" / "Restore Settings to Default Values";
And confirm by clicking Reset;
Close the browser and open it again.
After this process, check if you are in agreement.
Step 2
Note: If when opening Microsoft Edge, a Welcome tab opens, it means that the browser has been reset. Make a backup of your bookmarks before performing this action.
Close Microsoft Edge.
Open the start menu and type PowerShell.
Right-click Run As Administrator.
Copy and paste the command below:
Get-AppXPackage -AllUsers | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register "C:\Windows\SystemApps\*Edge*\AppXManifest.xml"}
$manifest = (Get-AppxPackage *Edge*).InstallLocation + '\AppxManifest.xml' ; Add-AppxPackage -DisableDevelopmentMode -Register $manifest
After the command execution is complete, try to open Microsoft Edge.
If the answer helped in any way, please mark it as an answer, if your question has not been solved, please post again.
I hope I helped, see you later!
I mean I'd like to know what difference it makes?
I have heard this a lot of times, but I am actually not sure about the reasons.
Help me to understand it properly?
I made a simple startup page, i used a template i found here on Reddit, and i was able to put it as the default page when i open a new tab and a new window. This page has all the links i use the most.
The thing is.. All the links open on a new tab, and i want to avoid this, since with every link i click, i now have two tabs, one with facebook (for example) and another one with the default page i made with the links.
Is there a way to avoid this? Make all my links open on the same tab without opening new ones.
I hope i make myself clear, english it's not my native language.