Just wanted to add that unfortunately the "preg_match('/\/Count [0-9]+/', $line, $matches" approach actually mis-reports sometimes, so you cannot rely on my two-fold approach. Even if it returns a number other than zero, it does not mean it is going to be correct. It usually is, but I have had at least half a dozen time now when it has been wrong. Sometimes off by only a few, but other times not even close!