CodeIgniter Forums

Full Version: FCPATH issue with multi-installation of codeigniter
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

[eluser]KLODEnet di Stefano Surricchio[/eluser]
I have some installation on my TestServer.
I want to explain this issue with a little example:

I have an installation of CodeIgniter (2.1.0) in a subfolder, "foo".
I use a library, that need to get the FCPATH in his construct.

Then, I have another installation of CodeIgniter (2.1.0) in another subfolder, "man".
Here I use the same library.

NOW... If I access to http://localhost/foo (or http://localhost/man) all works fine, but if I access to the OTHER installation, I get an error. The SECOND execution of CodeIgniter in the same Server in different subfolder, get the FCPATH of the FIRST execution. So, if I execute "foo" and then "man", to http://localhost/man the FCPATH constant results /www/foo and not /www/man. Otherwise, if I execute "man" and then "foo", to http://localhost/foo the FCPATH constant results /www/man and not /www/foo

in the "index.php" I set:

define('FCPATH', dirname(__FILE__));

and so, either installation works fine.