Ah OK, fair enough. Well I don't know if it helps you at all but this is
a modified version of a function I wrote to scan through the ZF library
classes for something else. It will return an array of all the classes,
and the files they have require_once lines for. Not as convenient as
what your proposing, and you may even have something better already, but
here it is in case it helps:
<?php
function scan($path, $trail = null)
{
$files = array();
$ignore = array('.', '..');
$dh = opendir($path);
while (false !== ($file = readdir($dh))) {
if (!in_array($file, $ignore)) {
if(is_dir($path . '/' . $file)) {
$files = array_merge($files, scan($path . '/' . $file,
$trail . '/' . $file));
} elseif(preg_match('/\.php$/i', $file)) {
$content = file_get_contents($path . '/' . $file);
preg_match_all('/require_once \'([^\']+)\';/i',
$content, $matches);
$files[$trail . '/' . $file] = $matches[1];
}
}
}
closedir($dh);
return $files;
}
$files = scan('E:\ZendFramework\1.0.0\library');
var_dump($files);
--
Jack