-- Juan Felipe Alavarez Saldarriaga <[EMAIL PROTECTED]> wrote
(on Wednesday, 26 September 2007, 04:25 PM +0000):
> This is my index.php code:
> 
> #
> # Checking modules integrity.
> #
> 
> /**
>  * Check the existence of a class.
>  *
>  * @param string $strClass Class name.
>  * @return void.
>  */
> function __autoload( $strClass )
> {
>     Zend_Loader::loadClass( $strClass );
> }

Try using:

    Zend_Loader::registerAutoload();

instead of the above; it uses spl_autoload, and will allow you to
register additional autoload routines in the future.

> // Load db.
> require_once( "index_db.php" );
> 
> And this is my index_db.php script code:
> 
> // Load DB info
> $arrDbConfig = array( 
>                               'host'     => $objConfiguration->database->host,

Where does $objConfiguration come from?

>                                 'username' => 
> $objConfiguration->database->username,
>                               'password' => 
> $objConfiguration->database->password,
>                               'dbname'   => $objConfiguration->database->name,
>                               'profiler' => 
> $objConfiguration->database->profiler
>                       );
> 
> // Set connection to the database.
> $objDb = Zend_Db::factory( $objConfiguration->database->type, $arrDbConfig );

What is the value of $ojbConfiguration->database->type? I'm guessing
that the error comes into play here, as that value is used to determine
which Zend_Db_Adapter to load.

-- 
Matthew Weier O'Phinney
PHP Developer            | [EMAIL PROTECTED]
Zend - The PHP Company   | http://www.zend.com/

Reply via email to