Here's the more efficient method:
$fh = fopen('/path/to/your/file.txt', 'r') or die($php_errormsg);
while (!feof($fh)) {
$line = fgets($fh, 4096);
if (preg_match($pattern, $line)) { $ora_books[ ] = $line; }
}
fclose($fh);
Since the first method reads in everything all at once,
it's about three times faster then the second way,
which parses the file line by line but uses less memory. One
downside, however, is that because the regular expression works only
on one line at a time, the second method doesn't
find strings that span multiple lines.