createCDATASection method
Creates a CDATA section that contains the specified text.
![]() ![]() |
Syntax
var newCDATASectionNode = document.createCDATASection(text);Parameters
- text [in]
-
Type: BSTR
A String value that contains the text to place inside the CDATA section.
- newCDATASectionNode [out, retval]
-
Type: IHTMLDOMNode
Returns a reference to the CDATA section.
Return value
Type: IHTMLDOMNode
Returns a reference to the CDATA section.Standards information
Remarks
The createCDATASection method is supported only for XML documents.
Examples
The following code example creates a CDATA section.
document.createCDATASection( "My content" );
See also
Show:

