4 include_once
'./Services/FileSystem/classes/class.ilFileSystemStorage.php';
35 if(!$settings->get(
'soap_user_administration',0))
50 return 'ilRestFileStorage';
81 $GLOBALS[
'ilLog']->write(__METHOD__.
' original name: '.$this->getPath().
'/'.$name);
83 $real_path = realpath($this->
getPath().
'/'.$name);
86 $GLOBALS[
'ilLog']->write(__METHOD__.
' no realpath found for: '.$this->getPath().
'/'.$name);
90 $file_name = basename($real_path);
91 $GLOBALS[
'ilLog']->write(__METHOD__.
' translated name: '.$this->getPath().
'/'.$file_name);
94 is_file($this->
getPath().
'/'.$file_name) &&
95 file_exists($this->
getPath().
'/'.$file_name)
98 $GLOBALS[
'ilLog']->write(__METHOD__.
' delivering file: ' . $this->getPath().
'/'.$file_name);
99 $return = file_get_contents($this->
getPath().
'/'.$file_name);
115 $GLOBALS[
'ilLog']->write(__METHOD__.
' file not found.');
133 $body = $request->post(
"content");
139 $return = basename($tmpname);
141 $GLOBALS[
'ilLog']->write(__METHOD__.
' Writing to path '.
$path);
153 return basename($tmpname);
158 return $this->
getPath().
'/'.$tmpname;
166 $max_age = time() - self::AVAILABILITY_IN_DAYS * 24 * 60 * 60;
168 foreach($ite as
$file)
170 if($file->getCTime() <= $max_age)
173 @unlink($file->getPathname());
176 $GLOBALS[
'ilLog']->write(__METHOD__.
' '. $e->getMessage());
static getInstance( $name='default')
Get Slim application with name.
createFile()
Get file by md5 hash.
init()
init and create directory
deleteDeprecated()
Delete deprecated files.
getStoredFilePath($tmpname)
getFile($name)
Get file by md5 hash.
getPathPostfix()
Get path prefix.
create()
Create directory.
writeToFile($a_data, $a_absolute_path)
Write data to file.
__construct()
Constructor.
const AVAILABILITY_IN_DAYS
storeFileForRest($content)
static ilTempnam($a_temp_path=null)
Create a temporary file in an ILIAS writable directory.
getPathPrefix()
Get path prefix.
responeNotFound()
Send not found response.
$GLOBALS['PHPCAS_CLIENT']
This global variable is used by the interface class phpCAS.
checkWebserviceActivation()
Check if soap administration is enabled.