I want to display the "hiOutsideTemp" value from this html page: http://amira.meteokrites.gr/ZWNTANA.htm to my page. It's a temp value.
I'm using the following code:
<?php
require_once 'simple_html_dom.php';
$html_string = file_get_contents('http://amira.meteokrites.gr/ZWNTANA.htm');
$dom = new DOMDocument();
libxml_use_internal_errors(true);
$dom->loadHTML($html_string);
libxml_clear_errors();
$xpath = new DOMXpath($dom);
$values = array();
$row = $xpath->query('//td[@id="/html/body/table/tbody/tr[7]/td[2]"]');
foreach($row as $value) {
$values[] = trim($value->textContent);
}
echo '<pre>';
print_r($values);
?>
But i get no result. What shall i do?