59 if(
$data[
'type'] !=
'file')
63 $file_parts = explode(
'.',
$name);
64 if(!is_numeric($file_parts[0]) or (strcmp(
'xml',$file_parts[1]) != 0))
68 $file_info[$file_parts[0]][
'size'] =
$data[
'size'];
69 $file_info[$file_parts[0]][
'date'] = $file_parts[0];
71 if($xml = simplexml_load_file($this->export_dir.
'/'.
$name))
74 foreach($xml->xpath(
'Record/Title') as
$title)
76 $records[] = (string)
$title;
78 $file_info[$file_parts[0]][
'name'] = $records;
81 return $file_info ? $file_info : array();
92 if(!@is_dir($this->export_dir))
114 if(!$fp = @fopen($this->export_dir.
'/'.time().
'.xml',
'w+'))
116 $ilLog->write(__METHOD__.
': Cannot open file '.$this->export_dir.
'/'.time().
'.xml');
117 $ilErr->raiseError(
'Cannot write export file.',$ilErr->WARNING);
134 if(!unlink($this->export_dir.
'/'.$a_timest.
'.xml'))
136 $ilLog->write(__METHOD__.
': Cannot delete file '.$this->export_dir.
'/'.$a_timest.
'.xml');
153 if(!@file_exists($this->export_dir.
'/'.$a_file_basename.
'.xml'))
155 $ilLog->write(__METHOD__.
': Cannot find file '.$this->export_dir.
'/'.$a_file_basename.
'.xml');
158 return $this->export_dir.
'/'.$a_file_basename.
'.xml';
169 if(!@is_dir($this->export_dir))