/ Published in: PHP
You know how to use it when you see the code, very simple. Just use files() method.
Example:
function __autoload($class)
{
$files = fuselogic_autoload::files($class);
foreach($files as $file)
{
if(@include_once($file)) break;
}
}
Example:
function __autoload($class)
{
$files = fuselogic_autoload::files($class);
foreach($files as $file)
{
if(@include_once($file)) break;
}
}
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
class fuselogic_autoload { function find1($class = null) { // 'class_name' -> 'class.class_name.php'; } function find2($class = null) { // 'ClassName' -> 'class.class_name.php'; $return = 'class.'.$return.'.php'; return $return; } function files($class = null) { $return[] = fuselogic_autoload::find1($class); $return[] = fuselogic_autoload::find2($class); return $return; } }