Table of Contents

<HTMLElement>.getHtml()

Returns the HTML content of an Element as String.

Usage:
String = Element.getHtml()
Member of:
HTMLElement
Parameter:
none
Returns:
The inner HTML of the element as String.

Examples

Simple example:

console.log(document.getElementById('foo').getHtml());

See also

More information