I want to extract content from a div, but not needed the contents from its childrens. I m using simplehtmldom
parser and the following code
//html code
<div id="frame">
Needed this content
<a href="#">Not needed</a>
</div>
//php code
$elem = file_get_html($url);
$content = $elem->find('div#frame')->plaintext;
echo $content;
but this code results,
Needed this contentNot needed
I want the result as,
Needed this content
How to change th code for getting that output. Help plz. thanks in advance