Posted: Tue May 03, 2005 12:30 pm
Code: Select all
<?php
$f = "http://www.kingsofchaos.com/stats.php?id=654760";
$site = file_get_contents($f);
$found = preg_match ('#<td><b>Army size:</b></td>[\n\s]*<td>([\d,]*?)</td>#', $site, $match);
if ($found){
echo 'Army size: '.$match[0];
}else{
echo 'No matches.';
}
?>