Results 1 to 6 of 6

Thread: PHP error message.

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2006
    Posts
    352

    PHP error message.

    Hi I am getting the below error message, how can I get around it ? Thanks

    Code:
    Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/lib/php/./templates/tmpl1//./templates/tmpl1/index.tpl.html) is not within the allowed path(s): (/home/:/usr/lib/php:/tmp) in /home/a1571937/public_html/smarty/core/core.get_include_path.php on line 34

  2. #2
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: PHP error message.

    this path:
    /usr/local/lib/php/./templates/tmpl1//./templates/tmpl1/index.tpl.html

    doesn't look right.

    You probably don't have access to that directory. Looks like it is out site of the www directory.
    My usual boring signature: Something

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Sep 2006
    Posts
    352

    Re: PHP error message.

    How can I sort out which piece of code is causing this so I may either adjust or remove ? Thanks

  4. #4
    VBA Nutter visualAd's Avatar
    Join Date
    Apr 2002
    Location
    Ickenham, UK
    Posts
    4,906

    Re: PHP error message.

    clamp, please check your facts before posting.

    The open_basedir directive which you will find in your httpd.conf or php.ini defines which directories scripts are allowed to access files in. In your case:

    /home/:/usr/lib/php:/tmp

    Thats:

    /home/
    /usr/lib/php
    /tmp

    You need to make sure the file which is being opened / included is in one of these paths. If it is not which it isn't in your case then you will get the above error. To fix this you either need to move the script or file you are trying to open to one of those paths or change you php.ini and add that path (which indecently is perfectly ok) to your open_basedir directive.
    PHP || MySql || Apache || Get Firefox || OpenOffice.org || Click || Slap ILMV || 1337 c0d || GotoMyPc For FREE! Part 1, Part 2

    | PHP Session --> Database Handler * Custom Error Handler * Installing PHP * HTML Form Handler * PHP 5 OOP * Using XML * Ajax * Xslt | VB6 Winsock - HTTP POST / GET * Winsock - HTTP File Upload

    Latest quote: crptcblade - VB6 executables can't be decompiled, only disassembled. And the disassembled code is even less useful than I am.

    Random VisualAd: Blog - Latest Post: When the Internet becomes Electricity!!


    Spread happiness and joy. Rate good posts.

  5. #5
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: PHP error message.

    Quote Originally Posted by visualAd
    clamp, please check your facts before posting.
    i gave no facts, only opinions
    My usual boring signature: Something

  6. #6
    I'm about to be a PowerPoster!
    Join Date
    Jan 2005
    Location
    Everywhere
    Posts
    13,647

    Re: PHP error message.

    This isn't the place for opinions.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width