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 include path

Discussion in 'General Discussion' started by KarterJK, Aug 19, 2004.

  1. KarterJK

    KarterJK Member

    Joined:
    Mar 26, 2004
    Messages:
    17
    Likes Received:
    0
    Trophy Points:
    1
    I have set up a new user, example

    www.domain.com

    can they put all of their php files in the cgi-bin folder, so when they do a

    include 'whatever.php'; from within a php file

    it will it automatically search the cgi-bin folder and run?

    Thanks ahead of time
     
  2. bking

    bking Well-Known Member

    Joined:
    Mar 1, 2004
    Messages:
    206
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    Sydney
    Not 100% sure, but they may be able to add something to this effect in their .htaccess in their DocumentRoot

    <IfModule mod_php4.c>
    php_value include_path = ".:/path/to/cgi-bin"
    </IfModule>
     
  3. KarterJK

    KarterJK Member

    Joined:
    Mar 26, 2004
    Messages:
    17
    Likes Received:
    0
    Trophy Points:
    1
    lol
    stupid me all i had to do was test it in the cgi-bin folder (which didnt work)

    If I add your suggestion to the htaccess file
    will that change the php include path for the whole system
    or does it just add it as a path

    I am reluctant to try it for fear of breaking something

    thanks for the reply
     
  4. bking

    bking Well-Known Member

    Joined:
    Mar 1, 2004
    Messages:
    206
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    Sydney
    If you add it to just the users homedirectory/public_html it will only take effect for that domain.
    Try it and see if it works... if it fails remove it. :)
     
Loading...

Share This Page