2016-07-31 20:44:31 +00:00
|
|
|
<?php
|
|
|
|
|
2018-05-05 00:30:16 +00:00
|
|
|
function getGeneratedFiles($dir, &$results = array())
|
|
|
|
{
|
|
|
|
$files = scandir($dir);
|
|
|
|
|
|
|
|
foreach ($files as $key => $value) {
|
|
|
|
$path = realpath($dir.DIRECTORY_SEPARATOR.$value);
|
|
|
|
if (!is_dir($path)) {
|
|
|
|
$results[] = $path;
|
|
|
|
} else if ($value != "." && $value != "..") {
|
|
|
|
getGeneratedFiles($path, $results);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return $results;
|
|
|
|
}
|
|
|
|
|
|
|
|
foreach (getGeneratedFiles("generated") as $filename)
|
|
|
|
{
|
|
|
|
if (!is_dir($filename)) {
|
|
|
|
include_once $filename;
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|