| @@ 718-744 (lines=27) @@ | ||
| 715 | */ |
|
| 716 | } |
|
| 717 | ||
| 718 | function getPicture($pic_id) |
|
| 719 | { |
|
| 720 | $shared_filehandler = $this->kernel->useModule('filemanager'); |
|
| 721 | $shared_filehandler->includeFile('AppendFile.php'); |
|
| 722 | ||
| 723 | $tmp_filehandler = new FileHandler($this->kernel, $pic_id); |
|
| 724 | $this->value['picture']['id'] = $pic_id; |
|
| 725 | $this->value['picture']['original']['icon_uri'] = $tmp_filehandler->get('icon_uri'); |
|
| 726 | $this->value['picture']['original']['name'] = $tmp_filehandler->get('file_name'); |
|
| 727 | $this->value['picture']['original']['width'] = $tmp_filehandler->get('width'); |
|
| 728 | $this->value['picture']['original']['height'] = $tmp_filehandler->get('height'); |
|
| 729 | $this->value['picture']['original']['file_uri'] = $tmp_filehandler->get('file_uri'); |
|
| 730 | ||
| 731 | if ($tmp_filehandler->get('is_image')) { |
|
| 732 | $tmp_filehandler->createInstance(); |
|
| 733 | $instances = $tmp_filehandler->instance->getList('include_hidden'); |
|
| 734 | foreach ($instances as $instance) { |
|
| 735 | $this->value['picture'][$instance['name']]['file_uri'] = $instance['file_uri']; |
|
| 736 | $this->value['picture'][$instance['name']]['name'] = $instance['name']; |
|
| 737 | $this->value['picture'][$instance['name']]['width'] = $instance['width']; |
|
| 738 | $this->value['picture'][$instance['name']]['height'] = $instance['height']; |
|
| 739 | } |
|
| 740 | } |
|
| 741 | ||
| 742 | return $this->value['picture']; |
|
| 743 | } |
|
| 744 | ||
| 745 | /** |
|
| 746 | * @todo is this still used after the introduction of publish and unpublish |
|
| 747 | */ |
|
| @@ 249-275 (lines=27) @@ | ||
| 246 | return $pages; |
|
| 247 | } |
|
| 248 | ||
| 249 | function getPicture($pic_id) |
|
| 250 | { |
|
| 251 | $shared_filehandler = $this->kernel->useModule('filemanager'); |
|
| 252 | $shared_filehandler->includeFile('AppendFile.php'); |
|
| 253 | ||
| 254 | $tmp_filehandler = new FileHandler($this->kernel, $pic_id); |
|
| 255 | $this->value['picture']['id'] = $pic_id; |
|
| 256 | $this->value['picture']['original']['icon_uri'] = $tmp_filehandler->get('icon_uri'); |
|
| 257 | $this->value['picture']['original']['name'] = $tmp_filehandler->get('file_name'); |
|
| 258 | $this->value['picture']['original']['width'] = $tmp_filehandler->get('width'); |
|
| 259 | $this->value['picture']['original']['height'] = $tmp_filehandler->get('height'); |
|
| 260 | $this->value['picture']['original']['file_uri'] = $tmp_filehandler->get('file_uri'); |
|
| 261 | ||
| 262 | if ($tmp_filehandler->get('is_image')) { |
|
| 263 | $tmp_filehandler->createInstance(); |
|
| 264 | $instances = $tmp_filehandler->instance->getList('include_hidden'); |
|
| 265 | foreach ($instances as $instance) { |
|
| 266 | $this->value['picture'][$instance['name']]['file_uri'] = $instance['file_uri']; |
|
| 267 | $this->value['picture'][$instance['name']]['name'] = $instance['name']; |
|
| 268 | $this->value['picture'][$instance['name']]['width'] = $instance['width']; |
|
| 269 | $this->value['picture'][$instance['name']]['height'] = $instance['height']; |
|
| 270 | } |
|
| 271 | } |
|
| 272 | ||
| 273 | return $this->value['picture']; |
|
| 274 | } |
|
| 275 | ||
| 276 | /** |
|
| 277 | * Returns the possible page types but with a binary index |
|
| 278 | * |
|