DOMCharacterData::remove

Removes the character data

&reftitle.description; public `void` `DOMCharacterData::remove`

Removes the character data.

&reftitle.examples;

### `DOMCharacterData::remove` example

Removes the character data.

    <?php
    $doc = new DOMDocument;
    $doc->loadXML("<container><![CDATA[hello]]><world/></container>");
    $cdata = $doc->documentElement->firstChild;

    $cdata->remove();

    echo $doc->saveXML();
    ?>

&example.outputs;

    <?xml version="1.0"?>
    <container><world/></container>

&reftitle.seealso;

- `DOMChildNode::remove`
- `DOMCharacterData::after`
- `DOMCharacterData::before`
- `DOMCharacterData::replaceWith`
- `DOMNode::removeChild`