Setting the Target
The target attribute provides a way of specifying to a browser how a link will open in the browser. The default behavior is to open the linked document in the same window/tab. By manually setting the attribute to "_self"
, the page also remains in the same window/tab.
Other values include:
"_blank"
- Opens the linked document in a new window or tab"_parent"
- Opens the linked document in the parent frame"_top"
- Opens the linked document in the full body of the window"framename"
- Opens the linked document in a named frame
HTML
<a href="#" target="_blank">link text</a>
html
- Previous
- Next