concrete/src/File/Service/File.php
public function getTemporaryDirectory()
    {
        $temp = Config::get('concrete.filesystem.temp_directory');
        if ($temp && @is_dir($temp)) {
            return $temp;
        }

        if (!is_dir(DIR_FILES_UPLOADED_STANDARD . '/tmp')) {
            @mkdir(DIR_FILES_UPLOADED_STANDARD . '/tmp', Config::get('concrete.filesystem.permissions.directory'));
            @chmod(DIR_FILES_UPLOADED_STANDARD . '/tmp', Config::get('concrete.filesystem.permissions.directory'));
            @touch(DIR_FILES_UPLOADED_STANDARD . '/tmp/index.html');
        }

        if (is_dir(DIR_FILES_UPLOADED_STANDARD . '/tmp') && is_writable(DIR_FILES_UPLOADED_STANDARD . '/tmp')) {
            return DIR_FILES_UPLOADED_STANDARD . '/tmp';
        }

        if ($temp = getenv('TMP')) {
            return str_replace(DIRECTORY_SEPARATOR, '/', $temp);
        }
        if ($temp = getenv('TEMP')) {
            return str_replace(DIRECTORY_SEPARATOR, '/', $temp);
        }
        if ($temp = getenv('TMPDIR')) {
            return str_replace(DIRECTORY_SEPARATOR, '/', $temp);
        }

        $temp = @tempnam(__FILE__, '');
        if (file_exists($temp)) {
            unlink($temp);

            return str_replace(DIRECTORY_SEPARATOR, '/', dirname($temp));
        }
    }
public function getTemporaryDirectory()
    {
        $temp = Config::get('concrete.filesystem.temp_directory');
        if ($temp && @is_dir($temp)) {
            return $temp;
        }

        if (!is_dir(DIR_FILES_UPLOADED_STANDARD . '/tmp')) {
            @mkdir(DIR_FILES_UPLOADED_STANDARD . '/tmp', Config::get('concrete.filesystem.permissions.directory'));
            @chmod(DIR_FILES_UPLOADED_STANDARD . '/tmp', Config::get('concrete.filesystem.permissions.directory'));
            @touch(DIR_FILES_UPLOADED_STANDARD . '/tmp/index.html');
        }

        if (is_dir(DIR_FILES_UPLOADED_STANDARD . '/tmp') && is_writable(DIR_FILES_UPLOADED_STANDARD . '/tmp')) {
            return DIR_FILES_UPLOADED_STANDARD . '/tmp';
        }

        if ($temp = getenv('TMP')) {
            return str_replace(DIRECTORY_SEPARATOR, '/', $temp);
        }
        if ($temp = getenv('TEMP')) {
            return str_replace(DIRECTORY_SEPARATOR, '/', $temp);
        }
        if ($temp = getenv('TMPDIR')) {
            return str_replace(DIRECTORY_SEPARATOR, '/', $temp);
        }

        $temp = @tempnam(__FILE__, '');
        if (file_exists($temp)) {
            unlink($temp);

            return str_replace(DIRECTORY_SEPARATOR, '/', dirname($temp));
        }
    }
public function getTemporaryDirectory ( ) { $ temp = Config :: get ( 'concrete.filesystem.temp_directory' ) ; if ( $ temp && @ is_dir ( $ temp ) ) { return $ temp ; } if ( ! is_dir ( DIR_FILES_UPLOADED_STANDARD . '/tmp' ) ) { @ mkdir ( DIR_FILES_UPLOADED_STANDARD . '/tmp' , Config :: get ( 'concrete.filesystem.permissions.directory' ) ) ; @ chmod ( DIR_FILES_UPLOADED_STANDARD . '/tmp' , Config :: get ( 'concrete.filesystem.permissions.directory' ) ) ; @ touch ( DIR_FILES_UPLOADED_STANDARD . '/tmp/index.html' ) ; } if ( is_dir ( DIR_FILES_UPLOADED_STANDARD . '/tmp' ) && is_writable ( DIR_FILES_UPLOADED_STANDARD . '/tmp' ) ) { return DIR_FILES_UPLOADED_STANDARD . '/tmp' ; } if ( $ temp = getenv ( 'TMP' ) ) { return str_replace ( DIRECTORY_SEPARATOR , '/' , $ temp ) ; } if ( $ temp = getenv ( 'TEMP' ) ) { return str_replace ( DIRECTORY_SEPARATOR , '/' , $ temp ) ; } if ( $ temp = getenv ( 'TMPDIR' ) ) { return str_replace ( DIRECTORY_SEPARATOR , '/' , $ temp ) ; } $ temp = @ tempnam ( __FILE__ , '' ) ; if ( file_exists ( $ temp ) ) { unlink ( $ temp ) ; return str_replace ( DIRECTORY_SEPARATOR , '/' , dirname ( $ temp ) ) ; } }
Returns the full path to the temporary directory.

@return string
Returns the full path to the temporary directory .