12345678910111213141516171819202122232425262728293031323334 |
- <?php
-
- spl_autoload_register(function ($class) {
-
-
- $prefix = 'SCF\\';
-
-
- $base_dir = __DIR__ . '/Application/scf/';
-
-
- $len = strlen($prefix);
- if (strncmp($prefix, $class, $len) !== 0) {
-
- return;
- }
-
-
- $relative_class = substr($class, $len);
-
-
-
-
- $file = $base_dir . str_replace('\\', '/', $relative_class) . '.php';
-
-
- if (file_exists($file)) {
- require $file;
- }
-
- });
|