I'm probably missing something ... but the DOM object is empty in this code:
$ input = file_get_contents ('http://www.google.com/'); $ Doc = new DOMDocument (); @ $ Doctor & gt; LoadHTML ($ input); // Problems with invalid HTML var_dump ($ doc); Die ();
I do not know what could be wrong with that code, I've verified that $ input is actually full of the HTML page's HTML content.
Output is: Object (DOMDocument) # 3 (0) {}
Why do you understand ...
This is expected behavior to use HTML (or) to view.
Comments
Post a Comment