HTML DOM Progress Obheto
Progress object
Progress object is a new object in HTML5.
Progress object represents the HTML <progress> element.
<progress> element represents the progress of a task.
Access Progress Object
You can access the <progress> element using getElementById():
var x = document.getElementById("myProgress");
Create Progress Object
You can create a <progress> element using the document.createElement() method:
var x = document.createElement("PROGRESS");
Progress Object Attributes
属性 | Description |
---|---|
labels | Return the list of labels of the progress bar (if any). |
max | Set or return the max attribute value of the progress bar. |
position | 返回进度条的当前位置。 |
value | 设置或返回进度条的 value 属性值。 |
相关页面
HTML 参考手册:HTML <progress> 标签