Thuộc tính dữ liệu HTML <object>

❮ Thẻ HTML <object>

Thí dụ

Cách sử dụng phần tử <object> để nhúng hình ảnh:

<object data="pic_trulli.jpg" width="300" height="200"</object>

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

Thuộc datatính chỉ định URL của tài nguyên sẽ được đối tượng sử dụng.


Hỗ trợ trình duyệt

Attribute
data Yes Yes Yes Yes Yes

Cú pháp

<object data="URL">

Giá trị thuộc tính

Value Description
URL Specifies the URL of the resource to be used by the object.

Possible values:

  • An absolute URL - points to data on another web site (like href="http://www.example.com/images/pic_trulli.jpg")
  • A relative URL - points to data within a web site (like href="pic_trulli.jpg")

❮ Thẻ HTML <object>