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-CGI and php_value ?

Discussion in 'General Discussion' started by Sh3nKo, Aug 27, 2008.

  1. Sh3nKo

    Sh3nKo Member

    Joined:
    Sep 25, 2007
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    1
    Hello,

    I have to modify the php5 handler to cgi recently for use correctly cms like Joomla (rights problems).

    The problem is my .htaccess now return an error 500 :

    Code:
    Invalid command 'php_value', perhaps
    mis-spelled or defined by a module not included in the server configuration
    How can I stay in cgi and correctly execute directives like php_value ?

    Sorry for my English !
     
  2. Sh3nKo

    Sh3nKo Member

    Joined:
    Sep 25, 2007
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    1
    Up ! I need help!

    I must install php4 in Apache module or I have an alternative solution ??

    Thank you.
     
  3. FreedomBI

    FreedomBI Well-Known Member

    Joined:
    Jul 7, 2008
    Messages:
    65
    Likes Received:
    0
    Trophy Points:
    6
    For cgi, .htaccess doesn't work. You need a php.ini (at each level which has a script that could be called) with the correct values.
     
  4. Sh3nKo

    Sh3nKo Member

    Joined:
    Sep 25, 2007
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    1
    Thank you.

    For example, I have a .htaccess in /home/mysite/public_html who contains :

    Code:
    php_value session.save_path /home/mysite/public_html/sessions
    I must create a php.ini file with this line (php_value session.save_path /home/mysite/public_html/sessions) in /home/mysite/public_html ?
     
  5. MaestriaNick

    MaestriaNick Well-Known Member

    Joined:
    Aug 6, 2008
    Messages:
    159
    Likes Received:
    3
    Trophy Points:
    18
    no, that is wrong. The syntax for setup variables in php.ini will be different. For session path it is like this


    session.save_path = /PATH/TO/FOLDER

    Better, you copy an existing php.ini (may be the global one ) and modify the values in php.ini file, which you want to change.
     
  6. Sh3nKo

    Sh3nKo Member

    Joined:
    Sep 25, 2007
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    1
    Thank you for your response.

    But in what "/home/mysite/public_html/sessions" is different to "/PATH/TO/FOLDER" ?

    In "/PATH/TO/FOLDER" you wan't to say for example "/sessions" if my .htaccess is localized in /home/mysite/public_html/.htaccess ?

    Sorry I don't understand..
     
Loading...

Share This Page