Пример #1
0
function require_js($_dir = "./")
{
    $tempArray = [];
    $temp = subFolderFile($_dir);
    foreach ($temp as $i) {
        array_push($tempArray, $_dir . "/" . $i);
    }
    return $tempArray;
}
Пример #2
0
function requireComponents($_path, $_local = true)
{
    $path = getJFolder($_path, $_local, debug_backtrace());
    if (file_exists($path)) {
        $files = subFolderFile($path);
        foreach ($files as $i) {
            if (isPhp($path . "/" . $i)) {
                requireComponent($path . "/" . $i, false, 0);
            }
        }
    } else {
        requireError($_path);
    }
}