Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.php > #6394 > unrolled thread
| Started by | jans <janis.rough@gmail.com> |
|---|---|
| First post | 2012-06-20 13:11 -0700 |
| Last post | 2012-06-21 18:20 +0200 |
| Articles | 8 — 6 participants |
Back to article view | Back to comp.lang.php
can't modify include path jans <janis.rough@gmail.com> - 2012-06-20 13:11 -0700
Re: can't modify include path Jerry Stuckle <jstucklex@attglobal.net> - 2012-06-20 17:16 -0400
Re: can't modify include path jans <janis.rough@gmail.com> - 2012-06-20 18:37 -0700
Re: can't modify include path Arno Welzel <usenet@arnowelzel.de> - 2012-06-21 09:37 +0200
Re: can't modify include path Allodoxaphobia <knock_yourself_out@example.net> - 2012-06-21 11:27 +0000
Re: can't modify include path Arno Welzel <usenet@arnowelzel.de> - 2012-06-21 14:46 +0200
Re: can't modify include path "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-06-21 14:53 +0200
Re: can't modify include path "J.O. Aho" <user@example.net> - 2012-06-21 18:20 +0200
| From | jans <janis.rough@gmail.com> |
|---|---|
| Date | 2012-06-20 13:11 -0700 |
| Subject | can't modify include path |
| Message-ID | <2df59c0e-ddb9-4088-9b7f-d739dac4bcd5@googlegroups.com> |
I did a locate php.ini on my Mac. I found 5 php.ini. Why do I have so many? I installed a Filemaker Web Sesrver and it added a php.ini. I also had Tiger OS and then upgraded to Leopard OS. I think APple may have changed where the php.ini was for Apache 2. I also may have installed PHP version 5 and entropy build. I added the include path to all of these one by one to see which was the current php.ini. It turns out I still don't have an include path in the info.php. I'm trying to track this down and figure out which one is my php.ini
I think one of these versions, maybe the entropy version, added this php-config . Maybe this version was trying to upgrade the Tiger OS to PHP 5 and added this config file? I don't know but my include path should be:
include_path = ".:/usr/local/php5/include:/users/jr/pear/share/pear"
Can I change this php-config to have this include_path? I don't have Zend running on this server but the extension directory looks right and it is targeting the right php source. I would like to have the include path working so I can install xdebug and use PEAR.
thanks,
#! /bin/sh
SED="/usr/bin/sed"
prefix="/usr/local/php5"
exec_prefix="${prefix}"
version="5.2.4"
vernum="50204"
include_dir="${prefix}/include/php"
includes="-I$include_dir -I$include_dir/main -I$include_dir/TSRM -I$include_dir/Zend -I$include_dir/ext -I$include_dir/ext/date/lib"
ldflags=" -L/usr/local/php5/lib"
libs=" -lc-client -lz -liconv -liodbc -lm -lz -lldap -llber -lssl -lcrypto -lpam -liconv -lt1 -lfreetype -lpng -lz -ljpeg -lssl -lcrypto -lbz2 -lz -lssl -lcrypto -lm -lxml2 -lz -liconv -lm -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lxml2 -lz -liconv -lm -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lxml2 -lz -liconv -lm -lnetsnmp -lcrypto -lz -lm -lxml2 -lz -liconv -lm -lxml2 -lz -liconv -lm -lxml2 -lz -liconv -lm -lxml2 -lz -liconv -lm -lxml2 -lz -liconv -lm -lxml2 -lz -liconv -lm "
extension_dir='/usr/local/php5/lib/php/extensions/no-debug-non-zts-20060613'
program_prefix=""
program_suffix=""
exe_extension=""
php_cli_binary=NONE
php_cgi_binary=NONE
[toc] | [next] | [standalone]
| From | Jerry Stuckle <jstucklex@attglobal.net> |
|---|---|
| Date | 2012-06-20 17:16 -0400 |
| Message-ID | <jrtejt$1l4$1@dont-email.me> |
| In reply to | #6394 |
On 6/20/2012 4:11 PM, jans wrote: > I did a locate php.ini on my Mac. I found 5 php.ini. Why do I have so many? I installed a Filemaker Web Sesrver and it added a php.ini. I also had Tiger OS and then upgraded to Leopard OS. I think APple may have changed where the php.ini was for Apache 2. I also may have installed PHP version 5 and entropy build. I added the include path to all of these one by one to see which was the current php.ini. It turns out I still don't have an include path in the info.php. I'm trying to track this down and figure out which one is my php.ini > > I think one of these versions, maybe the entropy version, added this php-config . Maybe this version was trying to upgrade the Tiger OS to PHP 5 and added this config file? I don't know but my include path should be: > include_path = ".:/usr/local/php5/include:/users/jr/pear/share/pear" > Can I change this php-config to have this include_path? I don't have Zend running on this server but the extension directory looks right and it is targeting the right php source. I would like to have the include path working so I can install xdebug and use PEAR. > thanks, > See phpinfo() - it will tell you which config (if any) it's using, i.e. <?php phpinfo(); ?> Run the script on a page under your web server to see which .ini file the server's php is using, or from the cli with the php command to see which one the cli is using (they may be different). Also - php --ini from the command line will tell you which it is using. And yes, it's not unusual to have more than one php.ini file - unfortunately! <snip> -- ================== Remove the "x" from my email address Jerry Stuckle JDS Computer Training Corp. jstucklex@attglobal.net ==================
[toc] | [prev] | [next] | [standalone]
| From | jans <janis.rough@gmail.com> |
|---|---|
| Date | 2012-06-20 18:37 -0700 |
| Message-ID | <1c5ef5ec-c599-4e8f-b76c-f0c807acdf3f@googlegroups.com> |
| In reply to | #6395 |
On Wednesday, June 20, 2012 2:16:34 PM UTC-7, Jerry Stuckle wrote: > On 6/20/2012 4:11 PM, jans wrote: > > I did a locate php.ini on my Mac. I found 5 php.ini. Why do I have so many? I installed a Filemaker Web Sesrver and it added a php.ini. I also had Tiger OS and then upgraded to Leopard OS. I think APple may have changed where the php.ini was for Apache 2. I also may have installed PHP version 5 and entropy build. I added the include path to all of these one by one to see which was the current php.ini. It turns out I still don't have an include path in the info.php. I'm trying to track this down and figure out which one is my php.ini > > > > I think one of these versions, maybe the entropy version, added this php-config . Maybe this version was trying to upgrade the Tiger OS to PHP 5 and added this config file? I don't know but my include path should be: > > include_path = ".:/usr/local/php5/include:/users/jr/pear/share/pear" > > Can I change this php-config to have this include_path? I don't have Zend running on this server but the extension directory looks right and it is targeting the right php source. I would like to have the include path working so I can install xdebug and use PEAR. > > thanks, > > > > See phpinfo() - it will tell you which config (if any) it's using, i.e. > > <?php > phpinfo(); > ?> > > Run the script on a page under your web server to see which .ini file > the server's php is using, or from the cli with the php command to see > which one the cli is using (they may be different). > > Also - php --ini from the command line will tell you which it is using. > > And yes, it's not unusual to have more than one php.ini file - > unfortunately! > > <snip> > -- > ================== > Remove the "x" from my email address > Jerry Stuckle > JDS Computer Training Corp. > jstucklex@attglobal.net > ================== I tried the php --ini and it told me the right one is in /etc The only one in that directory is php.ini.default and I added the include_path to that ini and it is not showing up in php.info. the command said loaded ini file (/etc) additional parsed ini files(none) additional ini files (none) I restarted the web server apache. Just for fun I restarted my server. I still have .: for my include path. The php.ini.default include_path is: include_path = ".:/usr/local/php5/include:/users/jr/pear/share/pear" the permissions on this file is -r--r---r-- thanks
[toc] | [prev] | [next] | [standalone]
| From | Arno Welzel <usenet@arnowelzel.de> |
|---|---|
| Date | 2012-06-21 09:37 +0200 |
| Message-ID | <4FE2CF3A.7010400@arnowelzel.de> |
| In reply to | #6396 |
jans, 21.06.2012 03:37: > On Wednesday, June 20, 2012 2:16:34 PM UTC-7, Jerry Stuckle wrote: [...] >> >> See phpinfo() - it will tell you which config (if any) it's using, i.e. >> >> <?php >> phpinfo(); >> ?> [...] > I tried the php --ini and it told me the right one is in /etc Propably it told you, it WOULD load /etc/php.ini, if it was there. > The only one in that directory is php.ini.default and I added the include_path to that ini and it is not showing up in php.info. Make a copy of php.ini.default and rename to php.ini. > the command said > loaded ini file (/etc) > additional parsed ini files(none) > additional ini files (none) > > I restarted the web server apache. Just for fun I restarted my server. I still have .: for my include path. The php.ini.default include_path is: > include_path = ".:/usr/local/php5/include:/users/jr/pear/share/pear" This include path has nothing to do with the location php.ini at all! It is the path where PHP tries to locate files which you try to include within your scripts with include() or require(). -- Arno Welzel http://arnowelzel.de http://de-rec-fahrrad.de
[toc] | [prev] | [next] | [standalone]
| From | Allodoxaphobia <knock_yourself_out@example.net> |
|---|---|
| Date | 2012-06-21 11:27 +0000 |
| Message-ID | <slrnju618v.2p72.knock_yourself_out@shell.config.com> |
| In reply to | #6397 |
On Thu, 21 Jun 2012 09:37:30 +0200, Arno Welzel wrote: > jans, 21.06.2012 03:37: >> On Wednesday, June 20, 2012 2:16:34 PM UTC-7, Jerry Stuckle wrote: > [...] >>> >>> See phpinfo() - it will tell you which config (if any) it's using, i.e. >>> >>> <?php >>> phpinfo(); >>> ?> > [...] >> I tried the php --ini and it told me the right one is in /etc > > Propably it told you, it WOULD load /etc/php.ini, if it was there. Doesn't the command line PHP use a _different_ php.ini than the server PHP environment? That's always been my belief... Jonesy
[toc] | [prev] | [next] | [standalone]
| From | Arno Welzel <usenet@arnowelzel.de> |
|---|---|
| Date | 2012-06-21 14:46 +0200 |
| Message-ID | <jrv53u$ho0$2@dont-email.me> |
| In reply to | #6398 |
Am 21.06.2012 13:27, schrieb Allodoxaphobia: > On Thu, 21 Jun 2012 09:37:30 +0200, Arno Welzel wrote: >> jans, 21.06.2012 03:37: >>> On Wednesday, June 20, 2012 2:16:34 PM UTC-7, Jerry Stuckle wrote: >> [...] >>>> >>>> See phpinfo() - it will tell you which config (if any) it's using, i.e. >>>> >>>> <?php >>>> phpinfo(); >>>> ?> >> [...] >>> I tried the php --ini and it told me the right one is in /etc >> >> Propably it told you, it WOULD load /etc/php.ini, if it was there. > > Doesn't the command line PHP use a _different_ php.ini than the server > PHP environment? That's always been my belief... Yes - therefore Jerry S. recommended: "Run the script on a page under your web server to see which .ini file the server's php is using, or from the cli with the php command to see which one the cli is using (they may be different)." -- Arno Welzel http://arnowelzel.de http://de-rec-fahrrad.de
[toc] | [prev] | [next] | [standalone]
| From | "M. Strobel" <sorry_no_mail_here@nowhere.dee> |
|---|---|
| Date | 2012-06-21 14:53 +0200 |
| Message-ID | <a4gjqbFrc3U1@mid.uni-berlin.de> |
| In reply to | #6398 |
Am 21.06.2012 13:27, schrieb Allodoxaphobia: > On Thu, 21 Jun 2012 09:37:30 +0200, Arno Welzel wrote: >> jans, 21.06.2012 03:37: >>> On Wednesday, June 20, 2012 2:16:34 PM UTC-7, Jerry Stuckle wrote: >> [...] >>>> >>>> See phpinfo() - it will tell you which config (if any) it's using, i.e. >>>> >>>> <?php >>>> phpinfo(); >>>> ?> >> [...] >>> I tried the php --ini and it told me the right one is in /etc >> >> Propably it told you, it WOULD load /etc/php.ini, if it was there. > > Doesn't the command line PHP use a _different_ php.ini than the server > PHP environment? That's always been my belief... > > Jonesy > The setup of Opensuse and Ubuntu use different .ini files for command line and web server. And it makes sense. So the information from the web server executed phpinfo() is most relevant for the OP. I am just working on this subject with a self compiled PHP 5.4.4, and I can tell you that PHP is looking first for 'php-'.php_sapi_name().'.ini' file in the indicated directory, in my case php-apache2handler.ini php-cli.ini /Str.
[toc] | [prev] | [next] | [standalone]
| From | "J.O. Aho" <user@example.net> |
|---|---|
| Date | 2012-06-21 18:20 +0200 |
| Message-ID | <a4gvtjFo87U1@mid.individual.net> |
| In reply to | #6398 |
On 21/06/12 13:27, Allodoxaphobia wrote: > On Thu, 21 Jun 2012 09:37:30 +0200, Arno Welzel wrote: >> jans, 21.06.2012 03:37: >>> On Wednesday, June 20, 2012 2:16:34 PM UTC-7, Jerry Stuckle wrote: >> [...] >>>> >>>> See phpinfo() - it will tell you which config (if any) it's using, i.e. >>>> >>>> <?php >>>> phpinfo(); >>>> ?> >> [...] >>> I tried the php --ini and it told me the right one is in /etc >> >> Propably it told you, it WOULD load /etc/php.ini, if it was there. > > Doesn't the command line PHP use a _different_ php.ini than the server > PHP environment? That's always been my belief... Depends on the release of the PHP, as people already mentioned Ubuntu and SuSe, but while RedHat (guess it includes Fedora as it's their test environment) uses the same php.ini for both server and cli. -- //Aho
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.php
csiph-web