PHP Simple HTML DOM Parser some pages issue -
i have code read inputs in form.
the code works in demo page others, not work in pages. example issue:
facebook:
$url = 'https://www.facebook.com'; $html = file_get_html($url); $post = $html->find('form[id=reg]'); //id register facebook page print_r($post); print empty array.
functional example:
$url = 'http://www.monografias.com/usuario/registro'; $html = file_get_html($url); $post = $html->find('form[name=myform]'); print_r($post); print form content
facebook won't give registration form directly, respond basic html, , rest created javascript. see yourself
$url = 'https://www.facebook.com'; $html = file_get_html($url); echo htmlspecialchars($html); there no form "reg" id in html send you.
Comments
Post a Comment