Open link in same tab HTML | Example code

Use _self in target attribute of anchor tag to Open link in same tab in HTML webpage.

Example code open link in same tab HTML

A link will be open in the same window and in the same tab that contains the page with the link.

<html>
<body>
	<a target="_self" href="https://www.eyehunts.com" >EyeHunts.com</a>

</body>
</html>

Output:

Open link in same tab HTML

Do comment if you have any doubts and suggestion on this HTLM example code.

Note: The All HTML Examples codes are tested on the Firefox browser and the Chrome browser.

OS: Windows 10

Code: HTML 5 Version


Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.