I have an iframe that pops up on an HTML page. In the iframe popup there is a link. When a user clicks the link I want the link to open a new tab in the main browsers and not in the iframe. I have tried adding the following
<a href="http://www.google.com" target="_parent">Test</a>
all this does is open the page in the main browser (not in a new tab) therefore the user leaves the page.
Any help appreciated!
Here are some values for the
targetattribute_blank= Loads the page into a new browser window._self= Loads the page into the current window._parent= Loads the page into the parentW3C Docs here on target attribute (right at the bottom)
Updated: as pointed out by @Eregrith in the comments below – you cannot make the link open in a new tab – that is controlled client side (in the browser settings) you can open it in a different window – using
_blank