views:

175

answers:

1

Getting this error:

Fatal error: require_once() [function.require]: Failed opening required 'db/db.php' (include_path='/home/domain.ru/testerier/sites/application/../library:/home/domain.ru/testerier/sites/library:.:/usr/local/lib/php;/home/domain.ru/testerier/sites/application/models') in /home/domain.ru/testerier/sites/www/index.php on line 51

// Define path to application directory
defined('APPLICATION_PATH')
    || define('APPLICATION_PATH', realpath(dirname(__FILE__) . '/../application'));

// Define application environment
defined('APPLICATION_ENV')
    || define('APPLICATION_ENV', (getenv('APPLICATION_ENV') ? getenv('APPLICATION_ENV') : 'production'));

// Ensure library/ is on include_path
set_include_path(implode(PATH_SEPARATOR, array(
    realpath(APPLICATION_PATH . '/../library'),
    get_include_path(),
)).";".realpath(APPLICATION_PATH . '/models'));

It's working perfectly on the local machine. What's wrong?

A: 

Is your local machine a windwos machine and the server Linux? Then you might have a problem with case sensitivity. Windows is not case sensitive and therefore on windows Folder and folder are the same. On Linux they aren't. Maybe your library is actually Library or something.

tharkun
Local web server is on Windows XP. Ok i will try to make everything lowercase. I will post a picture of directories tree structure.
Beck
here it is http://i192.photobucket.com/albums/z228/Somebi/root.jpg
Beck
Yeah it seems it's case sensetive. But there indeed was some problem with models folder. I have moved it on one level upper and it's working now.Changed config:$includePath[] = '.';$includePath[] = './../models';$includePath[] = './../library';$includePath[] = get_include_path();$includePath = implode(PATH_SEPARATOR,$includePath);set_include_path($includePath);
Beck
Now i'm getting 500 Server Error code because of thiese lines in .htaccess geez what's wrong with this server...I'm not good at configuring .htaccess, could you please explain me, why all of these lines cause 500 server error?RewriteCond %{REQUEST_FILENAME} -s [OR]RewriteCond %{REQUEST_FILENAME} -l [OR]RewriteCond %{REQUEST_FILENAME} -d
Beck
Could be that mod_rewrite is not installed/enabled. Check your Apache error log, which should give you some more clues.
Tim Fountain
Thanks, i guess that's the reason. It was free hosting.
Beck