Obitu na DOM na HTML Caption

Caption object

The Caption object represents the HTML <caption> element.

Access Caption object

You can use getElementById() to access the <caption> element:

var x = document.getElementById("myCaption");

Try it yourself

Create Caption object

You can use the document.createElement() method to create a <caption> element:

var x = document.createElement("CAPTION");

Try it yourself

Tip:You can also use the createCaption method of the Table object to create a <caption> element.

Caption object properties

Attributes description
align

HTML5 does not support. Please use style.textAlign tun style.captionSide.

Dafi ko rarraba tabbatarin sabonin aiki.

Standard attributes and events

Caption objeq suka aiki tare da standardAttributeswaEvents.

Related pages

HTML Tutorial:HTML tabbatar

HTML Reference Manual:HTML <caption> tabbatar

JavaScript Reference Manual:HTML DOM Table objeq