When I connecting with $html = file_get_html("www.example.com") and server have opened port 80 but is empty (not have html code), function (for example) $html->find('a') is crashing...
Close this ticket, is a timeout error and php code.
An empty string is considered to be false, there is no analysis of the DOM of the page, and then immediately run you $dom->find, find method is running on a non-object (false), then you run the str_get_html function, and is necessary to check if it is false then the script has finished running, otherwise proceeds normally.
Close this ticket, is a timeout error and php code.
An empty string is considered to be false, there is no analysis of the DOM of the page, and then immediately run you $dom->find, find method is running on a non-object (false), then you run the str_get_html function, and is necessary to check if it is false then the script has finished running, otherwise proceeds normally.