Heres the updated code
<?php
ini_set('display_startup_errors', 1);
ini_set('display_errors', 1);
error_reporting(E_ALL);
$html = file_get_contents("http://www.philippinepcsolotto.com/results/swertres-results");
$dom = new DOMDocument();
$dom->loadHTML($html);
$xpath = new DomXPath($dom);
$nodes = $xpath->query('//span[@style="font-size:25px; color:#98293D"]');
foreach ($nodes as $node) {
echo $node->nodeValue;
}
?>
Now after adding new code and revising it errors pops out here is it
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Namespace prefix xmlns of attribute fb is not defined in Entity, line: 3 in /home/a8880105/public_html/try.php on line 12
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Tag header invalid in Entity, line: 182 in /home/a8880105/public_html/try.php on line 12
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Tag nav invalid in Entity, line: 195 in /home/a8880105/public_html/try.php on line 12
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Unexpected end tag : p in Entity, line: 222 in /home/a8880105/public_html/try.php on line 12
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Tag article invalid in Entity, line: 224 in /home/a8880105/public_html/try.php on line 12
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Tag header invalid in Entity, line: 225 in /home/a8880105/public_html/try.php on line 12
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Unexpected end tag : a in Entity, line: 233 in /home/a8880105/public_html/try.php on line 12
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Tag aside invalid in Entity, line: 316 in /home/a8880105/public_html/try.php on line 12
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Opening and ending tag mismatch: div and center in Entity, line: 496 in /home/a8880105/public_html/try.php on line 12
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Tag footer invalid in Entity, line: 503 in /home/a8880105/public_html/try.php on line 12
PHP Error Message
Warning: DOMDocument::loadHTML() [domdocument.loadhtml]: Unexpected end tag : a in Entity, line: 716 in /home/a8880105/public_html/try.php on line 12
Help anyone.