note 108921 deleted from function.spl-autoload-extensions by googleguy
| From: | googleguy@php.net | Date: | Sat, 12 Jan 2013 11:05:55 +0000 |
| Subject: | note 108921 deleted from function.spl-autoload-extensions by googleguy | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-192985@lists.php.net to get a copy of this message | ||
Note Submitter: office dot stojmenovic at gmail dot com
----
Simple example.
<?php
public function __construct()
{
spl_autoload_register(array($this,'library'));
}
public function library($class)
{
if (is_string($class) && null === $class) {
set_include_path(get_include_path().PATH_SEPARATOR.'app/lib/');
spl_autoload_extension('.php');
spl_autoload($class);
}
return false;
}
?>