HTML <a> Thuộc tính đích

❮ Thẻ HTML <a>

Thí dụ

Thuộc tính target chỉ định nơi mở tài liệu được liên kết:

<a href="https://www.w3schools.com" target="_blank">Visit W3Schools</a>

Định nghĩa và Cách sử dụng

Thuộc targettính chỉ định nơi để mở tài liệu được liên kết.


Hỗ trợ trình duyệt

Attribute
target Yes Yes Yes Yes Yes

Cú pháp

<a target="_blank|_self|_parent|_top|framename">

Giá trị thuộc tính

Value Description
_blank Opens the linked document in a new window or tab
_self Opens the linked document in the same frame as it was clicked (this is default)
_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 the named iframe

❮ Thẻ HTML <a>