parsing - PHP Simple HTML DOM Parser - error -


i have code:

<?php header('content-type: text/plain; charset=utf-8');  include('simple_html_dom.php'); $html = file_get_html('http://test.com/'); $class = $html->find("thisisatest", 0)->innertext;  echo $class; ?> 

error page:

<br /> <b>notice</b>:  trying property of non-object in <b>c:\xamp\htdocs\test\test.php</b> on line <b>6</b><br /> 

why works fine , getting error?

it useful print html see u getting. url getting redirected. helpful use curl more consistent results , error check


Comments

Popular posts from this blog

google chrome - Developer tools - How to inspect the elements which are added momentarily (by JQuery)? -

angularjs - Showing an empty as first option in select tag -

php - Cloud9 cloud IDE and CakePHP -