HTMLTableElement.createCaption()

The HTMLTableElement.createCaption() method returns the caption for the table. If no caption element exists on the table, this method creates it, then returns it.

Syntax

HTMLTableElement = table.createCaption()

Example

mycap = mytable.createCaption();

Specification

Browser compatibility

FeatureChromeEdgeFirefoxInternet ExplorerOperaSafari
Basic support Yes Yes Yes Yes Yes Yes
FeatureAndroid webviewChrome for AndroidEdge mobileFirefox for AndroidOpera AndroidiOS SafariSamsung Internet
Basic support Yes ? Yes Yes Yes Yes ?

Document Tags and Contributors

Contributors to this page: fscholz, teoli, kscarfone, Sheppy, ethertank, RobG, Dria, JesseW
Last updated by: fscholz,