2016-12-08 19:16:49 +00:00
|
|
|
<?php
|
|
|
|
|
2017-09-22 21:08:01 +00:00
|
|
|
error_reporting(E_ALL);
|
|
|
|
|
2016-12-08 19:16:49 +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;
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|