Hey people, I am trying to setup a local enviroment to test all my scripts and such before going live but I need to find a way I can set a different root path on so that weather I run the scripts on my server or local machine they will not have any problems finding the correct path. Currently if I try running any of my sites localy I get errors and all sorts because it is looking in the wrong places for everything so any help on this guys?
Try using the include_path functions. http://php.net/set_include_path It makes it easy to globally alter your a script's include paths.