Skip to content

Latest commit

 

History

History
22 lines (14 loc) · 406 Bytes

remove.md

File metadata and controls

22 lines (14 loc) · 406 Bytes

remove()

Removes all top level nodes, or if $selector is specified, the nodes matched by the selector.

Arguments

$selector

A CSS selector to refine the nodes to delete or null to delete top level nodes.

Example

$doc = new \hexydec\html\htmldoc();
if ($doc->load($html)) {
	$doc->remove('div.test');
}

Returns

The current htmldoc object with the requested nodes deleted.