Well, i am working with a framework that is composed of a somewhat complex file and directory structure.
in my application, i just need to require a file, like so:
require "framework/mainfile.php";
inside mainfile, it is including other files, like:
include "framework/classes/class1.php";
....
and inside some class files it is including other files in the same way;
what i need is to change the location of the framework files and thus the relative path to the framework files in order to have something like
include "lib/framework/mainfile.php";
but i don’t want to look in all the files and change the path in every one of them because i would always have to be doing it again when i change to a new version of the framework.
Is there any way of doing this?
use
set_include_path(implode(PATH_SEPARATOR, array(realpath('Your/updated/path'),
get_include_path(),
));
so your current include paths will not be effected
and you will not need to make change in all files