Re: help with shared php.ini

From: Date: Mon, 25 Dec 2000 04:19:34 +0000
Subject: Re: help with shared php.ini
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-31777@lists.php.net to get a copy of this message
I just tested this on my box. I don't have safe mode on, hope you don't either. My include path is "/home/httpd/php/:." Under /home/kjj I have public_html/ and phpinclude/. From /home/kjj/public_html/temp.php, I did include("../phpinclude/temp.lib"); and it worked fine. You should be able to do something similar to keep your includes outside of your html area without having to resort to absolute paths. "John W. Holmes" wrote: > > My hosting company has PHP compiled as a module, the include path is set to > "./:/usr/local/lib/php" (from phpinfo()) and I can include something with no > problem. include("index.html"); include the index file in the currect > directory as the script... > > I'm assuming that setting it to "./" will make it include in the same > directory as the script. If you wanted to include a file that was outside of > the web root, you could use a relative or absolute path and it should work > no problem, also. > > ---John Holmes... > > -----Original Message----- > From: Sergiy P Zhenochin [mailto:serega@ics.uci.edu] > Sent: Monday, December 25, 2000 12:17 PM > To: php-general@lists.php.net > Subject: [PHP] help with shared php.ini > > Hello. > > We placed our php scripts onto leased webspace. The problem is that > PHP4 is compiled as an Apache module and not a CGI interpreter. That's > why we cannot have our own php.ini file and all subscribers share global > php.ini. Right now it's a complete nightmare since include_path is set > to nonexisting directory, so we cannot execute include() function. If > the webhosting providers unset include_path , we'll be able to > include(), but will have to store all our files in the world-visible > directory? > Does anyone know any better way to use shared php.ini and still > store included files outside www tree? I tried include_path = $HOME/www > , it didn't quite work. > Thanks a lot. > Sergiy. > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#31777) next »