0

As I know, the root folder for a codeigniter app is set in "ci.php" with the $application_foldervariable.

Is it possible to change this variable dynamically ?

For example at at some point, in some controller, I want to switch the root dir from "main_root" folder to "another_root" folder ?

Alexander Nikolov
  • 1,871
  • 7
  • 27
  • 49

1 Answers1

0

The application folder is set in the index.php, for example:

$application_folder = '../application';

That is the best place to change it dynamically.

Joerg
  • 3,102
  • 2
  • 24
  • 30