Best way to autload class from multiple directory
<p>Hello I'm trying to load classes that are stored in separate directories.
I try with SPL but i must set load directory where to search. </p>

<p>My structure is like in Zend fw:</p>

<blockquote>
  <p>|--root</p>
  
  <p>|-- Library</p>
  
  <p>|---- database[dir]</p>
  
  <p>|---------adapter.php</p>
  
  <p>|---------results.php</p>
  
  <p>|-----registry[dir]</p>
  
  <p>|---------format.php</p>
  
  <p>|---------bla-bla.php</p>
  
  <p>|--index.php</p>
</blockquote>

<pre><code>function __autoload($class_name) 
{
    include LIB."database/".$class_name.".php";
    include LIB."registry/".$class_name.".php";
}
</code></pre>

<p>How to autoload all from library (all folders) without definig include LIB."database/","registry" </p>
