<?PHP
$file = file_get_contents('/root/ported_peerless_1012_list.txt');
$file = explode("\n", $file);
print_r($file);
foreach($file as $number){
$query = "select id, calldate from cdr where sipcalledip = '1297050818' and calldate >= '2012-10-19 00:00:00' and called = '$number' limit 1;";
$result = mysql_query($query);
if(mysql_num_rows($result) <> 1){
echo "Did not find DID $number\r\n";
}
}
?>