Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

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:
    51
    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:
    51
    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:
    56
    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:
    51
    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:
    68
    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.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  6. Sh3nKo

    Sh3nKo Member

    Joined:
    Sep 25, 2007
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    51
    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..
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice