Hello. I'm trying to learn how to implement the Zend framework. Supposedly, this tutorial is compatable with the most recent stable version 0.9.0 beta, but I'm running into loads of conflicts.
Zend::loadClass() is deprecated so it tells me to use Zend_Loader::loadClass(). No problem except that it can't find the Zend_Loader class.
First things first, the directory structure is okay and the file DOES exist because I found it: 'library/Zend/Loader.php', and was able to get rid of the error by using
require_once(Zend/Loader.php)
BUT I would have to do this for each class file(!), so there is obviously a problem with my include path setting that I need to figure out.
The tutorial tells you to set up the directory structure as follows:
/root
|--/application
|--|--/controllers
|--|--/models
|--|--/views
|--/library
|--|--/Zend.php
|--|--/Zend
|--|--|--/Loader.php
|--|--|--/Registry.php
|--|--|--/a bunch of other stuff...
|--/public
|--|--/images
|--|--/scripts
|--|--/styles
This is the set_include_path it says to use:
set_include_path('.' . PATH_SEPARATOR . './library' . PATH_SEPARATOR . './application/models/' . PATH_SEPARATOR . get_include_path());
include("Zend.php");
but it can't find the classes:
Fatal Error: Class 'Zend_Loader' not found in c:\Webs\zf_tutorial\index.php
so what am I doing wrong?