0

I want to open href link in new tab but the user stay on current page

href="/Money/terms" target="_self" Terms & Conditions

how its possible in HTML??

Mark Rotteveel
  • 90,369
  • 161
  • 124
  • 175
  • can't be done this behavior is control by the browser. take a look at [this answer](https://stackoverflow.com/questions/7522565/how-to-stay-on-current-window-when-the-link-opens-in-new-tab) – Niel Sep 23 '21 at 16:28
  • Are you trying to have the tab open behind the scenes without being active? This won't be supported in all browsers. You could probably use some javascript (https://stackoverflow.com/a/7924248/2272231) to re-focus the current window. – krchun Sep 23 '21 at 16:32

1 Answers1

0

simply change target="_self" to target="_blank" inside the anchor:

<a href="https://www.google.com" target="_blank">Link</a>
tacoshy
  • 5,858
  • 5
  • 9
  • 28
Keev studio
  • 149
  • 4