[PHP] Question about php.ini file

2007-11-04 Thread Jon Westcot
Hi all:

I've learned, much to my pleasure, that I can place a php.ini file in the 
root directory of my shared domain to allow some customization of the php 
settings.  However, when I do this, I keep getting weird results.  Some of the 
values that I change appear as I've asked them to be.  Some appear to not 
change at all.  And some have been changing to what appears to be default 
values for php.

I'm wondering a few things here.  First, my computer is Windows-based, but 
the server is Linux-based.  Do I need to somehow convert the Windows text file 
line termination characters to their Linux variants?  If so, how?  Is it 
possible that I'm trying to change values beyond some upper limit which is 
causing php to use the default value?

The main values that I'm trying to change are:

post_max_size
upload_max_filesize
memory_limit
max_execution_time
max_input_time

If anyone knows of upper limits for these, I'd appreciate learning about 
them.

As always, any help you can send my way will be greatly appreciated!

Thanks,

Jon


Re: [PHP] Question about php.ini file

2007-11-04 Thread Cristian Vrabie
You must take in count that before php even gets to receive something, 
it all passes through the HTTP server (apache or something). for most of 
these settings there are equivalents in the config file of the server 
that you need to change accordingly.
this might be the cause of the weird results. for example, if your limit 
for uploaded files is 10M in php but the server is set to accept max 5M, 
5M will be the limit


Jon Westcot wrote:

Hi all:

I've learned, much to my pleasure, that I can place a php.ini file in the 
root directory of my shared domain to allow some customization of the php 
settings.  However, when I do this, I keep getting weird results.  Some of the 
values that I change appear as I've asked them to be.  Some appear to not 
change at all.  And some have been changing to what appears to be default 
values for php.

I'm wondering a few things here.  First, my computer is Windows-based, but 
the server is Linux-based.  Do I need to somehow convert the Windows text file 
line termination characters to their Linux variants?  If so, how?  Is it 
possible that I'm trying to change values beyond some upper limit which is 
causing php to use the default value?

The main values that I'm trying to change are:

post_max_size
upload_max_filesize
memory_limit
max_execution_time
max_input_time

If anyone knows of upper limits for these, I'd appreciate learning about 
them.

As always, any help you can send my way will be greatly appreciated!

Thanks,

Jon

  


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Question about php.ini file

2007-11-04 Thread Jon Westcot
Hi Cristian:

Thanks for the replies.

In this case, what I've been noticing is that most of the values have
gone DOWN (i.e., gotten smaller) after I placed my own php.ini file in
place.  For example, upload_max_filesize was 8M before I placed my file,
but, afterwards, it was 2M!  I'm trying to increase this size, not decrease
it.

Could it be the line-ending characters that are causing the problem?
Could PHP be seeing the new file but not realizing how to process it, which
would cause the values to flop over to their defaults?

Thanks,

Jon

- Original Message -

 You must take in count that before php even gets to receive something,
 it all passes through the HTTP server (apache or something). for most of
 these settings there are equivalents in the config file of the server
 that you need to change accordingly.
 this might be the cause of the weird results. for example, if your limit
 for uploaded files is 10M in php but the server is set to accept max 5M,
 5M will be the limit

 Jon Westcot wrote:
  Hi all:
 
  I've learned, much to my pleasure, that I can place a php.ini file
in the root directory of my shared domain to allow some customization of the
php settings.  However, when I do this, I keep getting weird results.  Some
of the values that I change appear as I've asked them to be.  Some appear to
not change at all.  And some have been changing to what appears to be
default values for php.
 
  I'm wondering a few things here.  First, my computer is
Windows-based, but the server is Linux-based.  Do I need to somehow convert
the Windows text file line termination characters to their Linux variants?
If so, how?  Is it possible that I'm trying to change values beyond some
upper limit which is causing php to use the default value?
 
  The main values that I'm trying to change are:
 
  post_max_size
  upload_max_filesize
  memory_limit
  max_execution_time
  max_input_time
 
  If anyone knows of upper limits for these, I'd appreciate learning
about them.
 
  As always, any help you can send my way will be greatly appreciated!
 
  Thanks,
 
  Jon

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Question about php.ini file

2007-11-04 Thread Nathan Nobbe
On 11/4/07, Jon Westcot [EMAIL PROTECTED] wrote:

 Hi Cristian:

 Thanks for the replies.

 In this case, what I've been noticing is that most of the values have
 gone DOWN (i.e., gotten smaller) after I placed my own php.ini file in
 place.  For example, upload_max_filesize was 8M before I placed my file,
 but, afterwards, it was 2M!  I'm trying to increase this size, not
 decrease
 it.

 Could it be the line-ending characters that are causing the problem?
 Could PHP be seeing the new file but not realizing how to process it,
 which
 would cause the values to flop over to their defaults?


do you have ssh access to the server?
i recommend you start out by creating the simplest file you can by editing
it
directly on the linux server, via vim or w/e.
then using a phpinfo() script, you should see your overridden value in the
left
column (those are for the locally overridden values).
some other things to note are;

   1. apache must be properly configured to allow the .htaccess
   overrides.
   2. you cant override all the values in php.ini; see the documentation

regarding which ones can be overriden and where

here is an article regarding the process,
http://gentoo-wiki.com/HOWTO_php.ini_overrides_w/_.htaccess

-nathan


Re: [PHP] Question about php.ini file

2007-11-04 Thread Jon Westcot
Hi Nathan:

I'm not certain if I have all of the items you've mentioned, but I'll look 
into it.  And thanks for the link; I'll check that out, too.

Jon

- Original Message - 
From: Nathan Nobbe 
To: Jon Westcot 
Cc: PHP General 
Sent: Sunday, November 04, 2007 5:05 PM
Subject: Re: [PHP] Question about php.ini file


On 11/4/07, Jon Westcot [EMAIL PROTECTED] wrote:
  Hi Cristian:

  Thanks for the replies.

  In this case, what I've been noticing is that most of the values have
  gone DOWN (i.e., gotten smaller) after I placed my own php.ini file in
  place.  For example, upload_max_filesize was 8M before I placed my file, 
  but, afterwards, it was 2M!  I'm trying to increase this size, not decrease
  it.

  Could it be the line-ending characters that are causing the problem?
  Could PHP be seeing the new file but not realizing how to process it, which 
  would cause the values to flop over to their defaults?

do you have ssh access to the server?
i recommend you start out by creating the simplest file you can by editing it
directly on the linux server, via vim or w/e. 
then using a phpinfo() script, you should see your overridden value in the left
column (those are for the locally overridden values).
some other things to note are;

  1.. apache must be properly configured to allow the .htaccess overrides. 
  2.. you cant override all the values in php.ini; see the documentation
regarding which ones can be overriden and where


here is an article regarding the process, 
http://gentoo-wiki.com/HOWTO_php.ini_overrides_w/_.htaccess

-nathan



Re: [PHP] Question about php.ini file

2007-11-04 Thread Jon Westcot
Hi Nathan:

Another quick question regarding the use of the .htaccess file:

If I'm trying to set something like post_max_size, which takes a shorthand 
value such as 16M in place of the full value, will using the php_value type of 
statement also accept the shorthand value, or do I need to place in the full 
value?

Thanks again; this solution may be exactly what we need!

Jon

- Original Message - 
From: Nathan Nobbe 
To: Jon Westcot 
Cc: PHP General 
Sent: Sunday, November 04, 2007 5:05 PM
Subject: Re: [PHP] Question about php.ini file


On 11/4/07, Jon Westcot [EMAIL PROTECTED] wrote:
  Hi Cristian:

  Thanks for the replies.

  In this case, what I've been noticing is that most of the values have
  gone DOWN (i.e., gotten smaller) after I placed my own php.ini file in
  place.  For example, upload_max_filesize was 8M before I placed my file, 
  but, afterwards, it was 2M!  I'm trying to increase this size, not decrease
  it.

  Could it be the line-ending characters that are causing the problem?
  Could PHP be seeing the new file but not realizing how to process it, which 
  would cause the values to flop over to their defaults?

do you have ssh access to the server?
i recommend you start out by creating the simplest file you can by editing it
directly on the linux server, via vim or w/e. 
then using a phpinfo() script, you should see your overridden value in the left
column (those are for the locally overridden values).
some other things to note are;

  1.. apache must be properly configured to allow the .htaccess overrides. 
  2.. you cant override all the values in php.ini; see the documentation
regarding which ones can be overriden and where


here is an article regarding the process, 
http://gentoo-wiki.com/HOWTO_php.ini_overrides_w/_.htaccess

-nathan



Re: [PHP] Question about php.ini file

2007-11-04 Thread Jochem Maas
Jon Westcot wrote:
 Hi Nathan:
 
 Another quick question regarding the use of the .htaccess file:
 
 If I'm trying to set something like post_max_size, which takes a 
 shorthand value such as 16M in place of the full value, will using the 
 php_value type of statement also accept the shorthand value, or do I need to 
 place in the full value?

yes, valid values for ini settings are the same regardless of where you set 
them (.ini, apache conf, php script)

 
 Thanks again; this solution may be exactly what we need!
 
 Jon
 
 - Original Message - 
 From: Nathan Nobbe 
 To: Jon Westcot 
 Cc: PHP General 
 Sent: Sunday, November 04, 2007 5:05 PM
 Subject: Re: [PHP] Question about php.ini file
 
 
 On 11/4/07, Jon Westcot [EMAIL PROTECTED] wrote:
   Hi Cristian:
 
   Thanks for the replies.
 
   In this case, what I've been noticing is that most of the values have
   gone DOWN (i.e., gotten smaller) after I placed my own php.ini file in
   place.  For example, upload_max_filesize was 8M before I placed my file, 
   but, afterwards, it was 2M!  I'm trying to increase this size, not decrease
   it.
 
   Could it be the line-ending characters that are causing the problem?
   Could PHP be seeing the new file but not realizing how to process it, which 
   would cause the values to flop over to their defaults?
 
 do you have ssh access to the server?
 i recommend you start out by creating the simplest file you can by editing it
 directly on the linux server, via vim or w/e. 
 then using a phpinfo() script, you should see your overridden value in the 
 left
 column (those are for the locally overridden values).
 some other things to note are;
 
   1.. apache must be properly configured to allow the .htaccess overrides. 
   2.. you cant override all the values in php.ini; see the documentation
 regarding which ones can be overriden and where
 
 
 here is an article regarding the process, 
 http://gentoo-wiki.com/HOWTO_php.ini_overrides_w/_.htaccess
 
 -nathan
 
 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php