protected function remove(\DOMNodeList $elements)
    {
        $encoded = array('textarea', 'code');

        foreach ($elements as $element)
        {
            if ($this->childbearing($element))
            {
                continue;
            }

            $output = (string) $element->nodeValue;

            if (in_array($element->nodeName, $encoded))
            {
                $output = htmlentities($element->nodeValue);
            }

            array_push($this->data, (string) $output);

            $current = count($this->data) - 1;

            $element->nodeValue = '$' . $current . '$';
        }
    }
protected function remove(\DOMNodeList $elements)
    {
        $encoded = array('textarea', 'code');

        foreach ($elements as $element)
        {
            if ($this->childbearing($element))
            {
                continue;
            }

            $output = (string) $element->nodeValue;

            if (in_array($element->nodeName, $encoded))
            {
                $output = htmlentities($element->nodeValue);
            }

            array_push($this->data, (string) $output);

            $current = count($this->data) - 1;

            $element->nodeValue = '$' . $current . '$';
        }
    }
protected function remove ( \ DOMNodeList $ elements ) { $ encoded = array ( 'textarea' , 'code' ) ; foreach ( $ elements as $ element ) { if ( $ this -> childbearing ( $ element ) ) { continue ; } $ output = ( string ) $ element -> nodeValue ; if ( in_array ( $ element -> nodeName , $ encoded ) ) { $ output = htmlentities ( $ element -> nodeValue ) ; } array_push ( $ this -> data , ( string ) $ output ) ; $ current = count ( $ this -> data ) - 1 ; $ element -> nodeValue = '$' . $ current . '$' ; } }
Removes the content of single elements.

@param  \DOMNodeList $elements
@return void
Removes the content of single elements .