By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
457,933 Members | 1,574 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 457,933 IT Pros & Developers. It's quick & easy.

phpinfo() - strange results...

P: n/a
When I run phpinfo, it diaplays the same thing regardless of changes I make
to php.ini. For instance, php.ini shows register globals on max upload
filesize of 16M. etc, etc. But phpinfo always shows register globals off and
max file upload size of 2M. Any idea what is going on?

thanks,

brian
Dec 30 '06 #1
Share this Question
Share on Google+
6 Replies


P: n/a
..oO(Brian Huether)
>When I run phpinfo, it diaplays the same thing regardless of changes I make
to php.ini. For instance, php.ini shows register globals on max upload
filesize of 16M. etc, etc. But phpinfo always shows register globals off and
max file upload size of 2M. Any idea what is going on?
Did you edit the correct php.ini? phpinfo() also shows at the beginning
which php.ini was used.

Micha
Dec 30 '06 #2

P: n/a

"Michael Fesser" <ne*****@gmx.dewrote in message
news:oe********************************@4ax.com...
.oO(Brian Huether)
>>When I run phpinfo, it diaplays the same thing regardless of changes I
make
to php.ini. For instance, php.ini shows register globals on max upload
filesize of 16M. etc, etc. But phpinfo always shows register globals off
and
max file upload size of 2M. Any idea what is going on?

Did you edit the correct php.ini? phpinfo() also shows at the beginning
which php.ini was used.

Micha
Interesting. I noticed I had this in http.conf:

#ScriptAlias /php/ "c:/php/"
#AddType application/x-httpd-php .php
#Action application/x-httpd-php "/php/php.exe"

#try this:
# For PHP 4 do something like this:
LoadModule php4_module "c:/php/php4apache2.dll"
# Don't forget to copy the php4apache2.dll file from the sapi directory!
AddType application/x-httpd-php .php
# configure the path to php.ini
PHPIniDir "C:/php"

Funny thing is, I didn't even have php.ini in c:/php (is in c:/windows).
Though there is php.ini-dist
Does the system recognize that anyway?

I don't even remember switching to the php dll. But I did all sorts of stuff
to get ssl working about a year ago... didn't take notes.

thanks,

brian
Dec 30 '06 #3

P: n/a

"Brian Huether" <bh********@comcastSPAM.netwrote in message
news:rY******************************@comcast.com. ..
>
"Michael Fesser" <ne*****@gmx.dewrote in message
news:oe********************************@4ax.com...
>.oO(Brian Huether)
>>>When I run phpinfo, it diaplays the same thing regardless of changes I
make
to php.ini. For instance, php.ini shows register globals on max upload
filesize of 16M. etc, etc. But phpinfo always shows register globals off
and
max file upload size of 2M. Any idea what is going on?

Did you edit the correct php.ini? phpinfo() also shows at the beginning
which php.ini was used.

Micha

Interesting. I noticed I had this in http.conf:

#ScriptAlias /php/ "c:/php/"
#AddType application/x-httpd-php .php
#Action application/x-httpd-php "/php/php.exe"

#try this:
# For PHP 4 do something like this:
LoadModule php4_module "c:/php/php4apache2.dll"
# Don't forget to copy the php4apache2.dll file from the sapi directory!
AddType application/x-httpd-php .php
# configure the path to php.ini
PHPIniDir "C:/php"

Funny thing is, I didn't even have php.ini in c:/php (is in c:/windows).
Though there is php.ini-dist
Does the system recognize that anyway?

I don't even remember switching to the php dll. But I did all sorts of
stuff to get ssl working about a year ago... didn't take notes.

thanks,

brian
Actually, even when httpd.conf says c:/php is the php.ini location, phpinfo
says that c:/windows is Configuration File (php.ini) Path. Yet changing
c:/windows/php.ini does not cause changes to phpinfo output. (It does change
results if I specify c:/windows as ini path if httd.conf).

brian
Dec 30 '06 #4

P: n/a
Brian Huether wrote:
"Brian Huether" <bh********@comcastSPAM.netwrote in message
news:rY******************************@comcast.com. ..
>>"Michael Fesser" <ne*****@gmx.dewrote in message
news:oe********************************@4ax.com. ..
>>>.oO(Brian Huether)
When I run phpinfo, it diaplays the same thing regardless of changes I
make
to php.ini. For instance, php.ini shows register globals on max upload
filesize of 16M. etc, etc. But phpinfo always shows register globals off
and
max file upload size of 2M. Any idea what is going on?

Did you edit the correct php.ini? phpinfo() also shows at the beginning
which php.ini was used.

Micha

Interesting. I noticed I had this in http.conf:

#ScriptAlias /php/ "c:/php/"
#AddType application/x-httpd-php .php
#Action application/x-httpd-php "/php/php.exe"

#try this:
# For PHP 4 do something like this:
LoadModule php4_module "c:/php/php4apache2.dll"
# Don't forget to copy the php4apache2.dll file from the sapi directory!
AddType application/x-httpd-php .php
# configure the path to php.ini
PHPIniDir "C:/php"

Funny thing is, I didn't even have php.ini in c:/php (is in c:/windows).
Though there is php.ini-dist
Does the system recognize that anyway?

I don't even remember switching to the php dll. But I did all sorts of
stuff to get ssl working about a year ago... didn't take notes.

thanks,

brian


Actually, even when httpd.conf says c:/php is the php.ini location, phpinfo
says that c:/windows is Configuration File (php.ini) Path. Yet changing
c:/windows/php.ini does not cause changes to phpinfo output. (It does change
results if I specify c:/windows as ini path if httd.conf).

brian

Did you stop and restart Apache?

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================
Dec 30 '06 #5

P: n/a
Brian Huether napisał(a):
Actually, even when httpd.conf says c:/php is the php.ini location, phpinfo
says that c:/windows is Configuration File (php.ini) Path. Yet changing
c:/windows/php.ini does not cause changes to phpinfo output. (It does change
results if I specify c:/windows as ini path if httd.conf).
Restarting apache should help out the situation. *However* I have seen
that even though c:/php was set as the right path, php sometimes did
indeed use php.ini from c:/windows. Strange.
Regards,
--
Mateusz Papiernik, Maticomp Webdesign
ma**@maticomp.net, http://www.maticomp.net
"One man can make a difference" - Wilton Knight
Dec 30 '06 #6

P: n/a
"Brian Huether" <bh********@comcastSPAM.netwrote:
: Actually, even when httpd.conf says c:/php is the php.ini location,
: phpinfo says that c:/windows is Configuration File (php.ini) Path.
: Yet changing c:/windows/php.ini does not cause changes to phpinfo
: output. (It does change results if I specify c:/windows as ini path
: if httd.conf).

Hiya,

httpd.conf specifies where to load the php.dll for its use. Once
that's loaded, whenever a different library gets called, php looks
first in the folder the php.dll is installed. The list of paths
it searches, in the respective listed order...

(1) Directory containing the exe or dll.
(2) The current directory (this could vary as it could possibly
be the folder where a PHP is executing).
(3) The system folder (%systemroot%\system32).
(4) The %systemroot% folder (\Windows or \Winnt).
(5) The path environmental variable.

http://msdn.microsoft.com/library/en...lprocedure.asp

..INI files SHOULD get searched for in much the same way,
so if WINDOWS finds it inside the folder with the DLL it stops
searching at that point and loads that one.

My own httpd.conf file doesn't specify a location for php.ini.
It ends up finding it in the %systemroot% folder.

The php.ini is laid out quite nicely and provides a way to specify
where extensions get loaded from.

extension_dir = "C:/php5/extensions"

and all the extensions get placed in that folder.

Hope this helps.

--
Jim Carlock
Post replies to the group.
Dec 31 '06 #7

This discussion thread is closed

Replies have been disabled for this discussion.