Đối tượng nhân sự HTML DOM
Đối tượng nhân sự
Đối tượng HR đại diện cho phần tử HTML <hr>.
Truy cập đối tượng nhân sự
Bạn có thể truy cập phần tử <hr> bằng cách sử dụng getElementById():
Tạo đối tượng nhân sự
Bạn có thể tạo phần tử <hr> bằng cách sử dụng phương thức document.createElement():
Thuộc tính đối tượng nhân sự
Property | Description |
---|---|
align | Not supported in HTML5. Use style.textAlign instead. Sets or returns the alignment of a horizontal line |
color | Not supported in HTML5. Use style.color instead. Sets or returns the color of a horizontal line |
noshade | Not supported in HTML5. Sets or returns whether a horizontal line should render in one solid color (noshaded) |
size | Not supported in HTML5. Use style.height instead. Sets or returns the height of a horizontal line |
width | Not supported in HTML5. Use style.width instead. Sets or returns the width of a horizontal line |
Thuộc tính và sự kiện tiêu chuẩn
Đối tượng HR cũng hỗ trợ các thuộc tính và sự kiện tiêu chuẩn.
Trang liên quan
Tham chiếu HTML: thẻ HTML <hr>