Loading...
 
Architecture / Installation

Architecture / Installation


Re: Re: /tmp folder is not accessible, can't install

posts: 946

> I got a similar problem, I have a few ideas on what it could be, but dont know how to solve it, and even after having looked around for a solution for a few hours and tried some, it dosent seem to help me.. so now I post smile
>

>
Tiki Installer cannot proceed:

> The directory '/tmp' does not exist or PHP is not allowed to access it (check open_basedir entry in php.ini).

> ...


We had a similar problem, and we solved with this:

Modified this file ./lib/init/initlib.php

Orginal bit of code at ./lib/init/initlib.php (towards the end of the file)

Line 9 to 13 (numbers from the example below) need to be commented), and added line 8, to that it results as :

/** Return system defined temporary directory.
  * In Unix, this is usually /tmp
  * In Windows, this is usually c:\windows\temp or c:\winnt\temp
  * \static
  */
    function tempdir() {
        static $tempdir;

        if (!$tempdir) {
            $tempfile = tempnam(false,'');
            $tempdir = dirname($tempfile);
            @unlink($tempfile);
        } 
        return $tempdir;
    }

}

/** Return system defined temporary directory.
  * In Unix, this is usually /tmp
  * In Windows, this is usually c:\windows\temp or c:\winnt\temp
  * \static
  */
    function tempdir() {
        static $tempdir;
        $tempdir = '../tmp';
/*        if (!$tempdir) {
            $tempfile = tempnam(false,'');
            $tempdir = dirname($tempfile);
            @unlink($tempfile);
        } */
        return $tempdir;
    }

}

Upcoming Events

No records to display

Why Register?

Register at tiki.org and you'll be able to use the account at any *.tiki.org site, thanks to the InterTiki feature. A valid email address is required to receive site notifications and occasional newsletters. You can opt out of these items at any time.