Common folder between projects for extended libraries and helpers

I am wondering... There is a way to put all my extended libs and helpers in a shared folder so I can access they from different projects?


If I'm understanding correctly, yes you can do this. I've got many sites running off of one instance of CI.

Basically you'll want to put your system folder into a location that all of your sites can get access to. From there you'll just change your index.php to refer to your common instance of the system folder . For instance install CI system folder to: /usr/local/share/php/codeIgniter2-1/system/ and refer to that location in your index.php. You can still have your application code in the site directory if you want to keep that seperate. In that instance: /home/USERNAME/codeIgniter/application/config etc etc.

In the Index.php file you'd set $system_folder = "/usr/local/share/php/codeIgniter2-1/system" and you'd set $application_folder = "/home/USERNAME/codeIgniter/application"

Hope that helps.

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.