Use the target attribute to specify the target for opening the linked document in HTML. The following are the values of the target properties -
Properties | Description |
---|---|
_blank | Open the linked page in a new tab. |
self | Opens the linked page in the current tab. |
Open the linked page in the parent frame. | |
Top | Open the linked page in the top frame. |
You can try running the following code to achieve the targetProperties-
<!DOCTYPE html> <html> <head> <title>HTML target attribute</title> </head> <body> <h2>References</h2> <p>Refer the following <a href = "https://www.qries.com/questions.php" target = "_blank">website</a>.<br> The above link will open in a new tab.</p> </body> </html>
The above is the detailed content of How do we specify in HTML the target location for opening a linked document?. For more information, please follow other related articles on the PHP Chinese website!