bootstrap.php 401 B

123456789101112131415
  1. <?php
  2. require_once __DIR__ . '/../lib/common/customFunctions.php';
  3. spl_autoload_register(function (string $class) {
  4. $path = explode('\\', $class);
  5. $className = array_pop($path);
  6. array_shift($path);
  7. $path = strtolower(implode('/', $path));
  8. $path = __DIR__ . '/../lib/' . $path . '/' . $className . '.php';
  9. if (file_exists($path)) {
  10. require_once $path;
  11. }
  12. });