Was just an error . thanks to Eirik :

Quote :
Shouldn't the autoload file be called ./classes/autoload/autoload.php instead 
of ./classes/autoload/my_autoload.php?

Philippe

De : maxime.t...@gmail.com [mailto:maxime.t...@gmail.com] De la part de Maxime 
Thomas - Wascou
Envoyé : vendredi 2 avril 2010 16:51
À : VINCENT-ROYOL Philippe
Cc : components@lists.ez.no
Objet : Re: [Components] addClassRepository problem.

Hi,

It's seems that this fonction excepts the name of the autoload file to 
autoload.php and not my_autoload.php.

Max

2010/4/2 VINCENT-ROYOL Philippe 
<p.vincent-ro...@fhf.fr<mailto:p.vincent-ro...@fhf.fr>>
Hi dear community,

                I cant find where my fault is.. I would like to load eZCompents 
classes and some external classes files.
Directories look like this :

./classes/myclass.php
./classes/autoload/my_autoload.php
./lib/eZComponents/
./lib/autoload.php
./index.php

On ./lib/autoload.php i wrote :

require_once "./lib/eZComponents/Base/src/base.php";

ezcBase::addClassRepository( './classes' );
/** Autoload classes **/
function __autoload( $className ) {
        ezcBase::autoload( $className );
}

On ./classes/autoload/my_autoload.php :

return array (
                'myclass' => '../classes/myclass.php',
        );

And on index.php i call ./lib/autoload.php. It works with eZComponents classes, 
but cant find my own classes .. Someone could help me please ?

Thanks
Philippe

--
Components mailing list
Components@lists.ez.no<mailto:Components@lists.ez.no>
http://lists.ez.no/mailman/listinfo/components

-- 
Components mailing list
Components@lists.ez.no
http://lists.ez.no/mailman/listinfo/components

Reply via email to