Đối tượng HTML DOM Ul
Đối tượng Ul
Đối tượng Ul đại diện cho phần tử HTML <ul>.
Truy cập đối tượng Ul
Bạn có thể truy cập phần tử <ul> bằng cách sử dụng getElementById():
Tạo một đối tượng Ul
Bạn có thể tạo phần tử <ul> bằng cách sử dụng phương thức document.createElement():
Thuộc tính đối tượng Ul
Property | Description |
---|---|
compact | Not supported in HTML5. Use
style.lineHeight instead. Sets or returns whether the unordered list should render smaller than normal, or not |
type | Not supported in HTML5. Use
style.listStyleType instead. Sets or returns the value of the type attribute of an unordered list |
Thuộc tính và sự kiện tiêu chuẩn
Đối tượng Ul hỗ trợ các thuộc tính và sự kiện tiêu chuẩn.
Trang liên quan
Hướng dẫn HTML: Danh sách HTML
Tham chiếu HTML: thẻ HTML <ul>