The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

php.ini will not load custom variables

Discussion in 'General Discussion' started by ghstber, Jan 13, 2006.

  1. ghstber

    ghstber Member

    Joined:
    Oct 7, 2005
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    1
    Hello.

    I have a php.ini file in the same directory as a php file containing the phpinfo() function. This lists the upload_max_filesize variable as 2M. The php.ini file contains the line 'upload_max_filesize = 10M'. PHP is compiled to use suEXEC, and this is confirmed by the fact that if I attempt to modify this variable using the .htaccess file it throws a 500 error. Any ideas why this is not picking up the change of variable size? You can see this at the following URL:

    http://cnfractalmusic.com/test.php
     
  2. Izzee

    Izzee Well-Known Member

    Joined:
    Feb 6, 2004
    Messages:
    469
    Likes Received:
    0
    Trophy Points:
    16
    IIRC the changes made in your php.ini file in a user directory does not reflect in the system's php.ini files and so would not be called in the phpinfo() function.

    Try and test whether the upload limit is actually being set by the directory's php.ini file. This may help to establish my recollection of this issue. CMIIW.

    :)
     
  3. ghstber

    ghstber Member

    Joined:
    Oct 7, 2005
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    1
    Setting it does not change the upload limit in reality. The upload fails anything greater than a little lower than 2mb. However, in the past, when I have done this the custom php.ini does in fact register a change in phpinfo(), which is why I am a bit confuddled.
     
  4. Izzee

    Izzee Well-Known Member

    Joined:
    Feb 6, 2004
    Messages:
    469
    Likes Received:
    0
    Trophy Points:
    16
    I just did a google for upload_max_filesize local value
    You could vary the key words to exclude all the phpinfo() references.

    This thread came up and lots more which might throw some light on this for you ;)

    http://bugs.php.net/bug.php?id=13125&edit=1

    :)
     
    #4 Izzee, Jan 13, 2006
    Last edited: Jan 13, 2006
  5. ghstber

    ghstber Member

    Joined:
    Oct 7, 2005
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    1
    Nope, all of those variables are changed. Here is the php.ini contents:

    max_execution_time = 1200
    memory_limit = 32M
    post_max_size = 32M
    file_uploads = 1
    upload_max_filesize = 32M
    error_log = error_log
    error_reporting = 2039
    log_errors = On
    register_globals = On
    report_memleaks = On
    variables_order = EGPCS
    session.auto_start = On
    session.use_trans_sid = On

    Also, no, we did not compile using --enable-memory-limit. Any other ideas?
     
  6. ghstber

    ghstber Member

    Joined:
    Oct 7, 2005
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    1
    Does anyone have any ideas?
     
  7. DavidR

    DavidR Well-Known Member

    Joined:
    Feb 25, 2003
    Messages:
    177
    Likes Received:
    0
    Trophy Points:
    16
    It seems to reflect 32M now, did you fix it? Care to share?

    David
     
Loading...

Share This Page