ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
class.ilContainer.php
Go to the documentation of this file.
1<?php
2/*
3 +-----------------------------------------------------------------------------+
4 | ILIAS open source |
5 +-----------------------------------------------------------------------------+
6 | Copyright (c) 1998-2006 ILIAS open source, University of Cologne |
7 | |
8 | This program is free software; you can redistribute it and/or |
9 | modify it under the terms of the GNU General Public License |
10 | as published by the Free Software Foundation; either version 2 |
11 | of the License, or (at your option) any later version. |
12 | |
13 | This program is distributed in the hope that it will be useful, |
14 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
16 | GNU General Public License for more details. |
17 | |
18 | You should have received a copy of the GNU General Public License |
19 | along with this program; if not, write to the Free Software |
20 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
21 +-----------------------------------------------------------------------------+
22*/
23
24// note: the values are derived from ilObjCourse constants
25// to enable easy migration from course view setting to container view setting
26
27require_once "./Services/Object/classes/class.ilObject.php";
28
39class ilContainer extends ilObject
40{
41 protected $order_type = 0;
42 protected $hiddenfilesfound = false;
43
44 // container view constants
45 const VIEW_SESSIONS = 0;
46 const VIEW_OBJECTIVE = 1;
47 const VIEW_TIMING = 2;
48 const VIEW_ARCHIVE = 3;
49 const VIEW_SIMPLE = 4;
50 const VIEW_BY_TYPE = 5;
51 const VIEW_INHERIT = 6;
52
54
55
56 const SORT_TITLE = 0;
57 const SORT_MANUAL = 1;
58 const SORT_ACTIVATION = 2;
59 const SORT_INHERIT = 3;
60 const SORT_CREATION = 4;
61
64
67
71
72
73 static $data_preloaded = false;
74
81 function ilContainer($a_id = 0, $a_call_by_reference = true)
82 {
83 parent::__construct($a_id, $a_call_by_reference);
84 }
85
86
87
93 {
94 $webspace_dir = ilUtil::getWebspaceDir();
95 $cont_dir = $webspace_dir."/container_data";
96 if (!is_dir($cont_dir))
97 {
98 ilUtil::makeDir($cont_dir);
99 }
100 $obj_dir = $cont_dir."/obj_".$this->getId();
101 if (!is_dir($obj_dir))
102 {
103 ilUtil::makeDir($obj_dir);
104 }
105 }
106
113 {
114 return $this->_getContainerDirectory($this->getId());
115 }
116
123 {
124 return ilUtil::getWebspaceDir()."/container_data/obj_".$a_id;
125 }
126
133 function getBigIconPath()
134 {
135 return self::_lookupIconPath($this->getId());
136 }
137
145 {
146 return self::_lookupIconPath($this->getId());
147 }
148
156 {
157 return self::_lookupIconPath($this->getId());
158 }
159
166 {
167 return self::_lookupIconPath($this->getId());
168 }
169
170
176 function setHiddenFilesFound($a_hiddenfilesfound)
177 {
178 $this->hiddenfilesfound = $a_hiddenfilesfound;
179 }
180
187 {
189 }
190
195 {
196 return $this->style_id;
197 }
198
202 function setStyleSheetId($a_style_id)
203 {
204 $this->style_id = $a_style_id;
205 }
206
215 function _lookupContainerSetting($a_id, $a_keyword, $a_default_value = NULL)
216 {
217 global $ilDB;
218
219 $q = "SELECT * FROM container_settings WHERE ".
220 " id = ".$ilDB->quote($a_id ,'integer')." AND ".
221 " keyword = ".$ilDB->quote($a_keyword ,'text');
222 $set = $ilDB->query($q);
223 $rec = $set->fetchRow(DB_FETCHMODE_ASSOC);
224
225 if(isset($rec['value']))
226 {
227 return $rec["value"];
228 }
229 if($a_default_value === NULL)
230 {
231 return '';
232 }
233 return $a_default_value;
234 }
235
236 function _writeContainerSetting($a_id, $a_keyword, $a_value)
237 {
238 global $ilDB;
239
240 $query = "DELETE FROM container_settings WHERE ".
241 "id = ".$ilDB->quote($a_id,'integer')." ".
242 "AND keyword = ".$ilDB->quote($a_keyword,'text');
243 $res = $ilDB->manipulate($query);
244
245 $query = "INSERT INTO container_settings (id, keyword, value) VALUES (".
246 $ilDB->quote($a_id ,'integer').", ".
247 $ilDB->quote($a_keyword ,'text').", ".
248 $ilDB->quote($a_value ,'text').
249 ")";
250 $res = $ilDB->manipulate($query);
251 }
252
253 public static function _getContainerSettings($a_id)
254 {
255 global $ilDB;
256
257 $res = array();
258
259 $sql = "SELECT * FROM container_settings WHERE ".
260 " id = ".$ilDB->quote($a_id ,'integer');
261 $set = $ilDB->query($sql);
262 while($row = $ilDB->fetchAssoc($set))
263 {
264 $res[$row["keyword"]] = $row["value"];
265 }
266
267 return $res;
268 }
269
270 public static function _deleteContainerSettings($a_id, $a_keyword = null, $a_keyword_like = false)
271 {
272 global $ilDB;
273
274 if(!$a_id)
275 {
276 return;
277 }
278
279 $sql = "DELETE FROM container_settings WHERE ".
280 " id = ".$ilDB->quote($a_id ,'integer');
281 if($a_keyword)
282 {
283 if(!$a_keyword_like)
284 {
285 $sql .= " AND keyword = ".$ilDB->quote($a_keyword, "text");
286 }
287 else
288 {
289 $sql .= " AND ".$ilDB->like("keyword", "text", $a_keyword);
290 }
291 }
292 $ilDB->manipulate($sql);
293 }
294
295 public static function _exportContainerSettings(ilXmlWriter $a_xml, $a_obj_id)
296 {
297 // container settings
298 $settings = self::_getContainerSettings($a_obj_id);
299 if(sizeof($settings))
300 {
301 $a_xml->xmlStartTag("ContainerSettings");
302
303 foreach($settings as $keyword => $value)
304 {
305 // :TODO: proper custom icon export/import
306 if(stristr($keyword, "icon"))
307 {
308 continue;
309 }
310
311 $a_xml->xmlStartTag(
312 'ContainerSetting',
313 array(
314 'id' => $keyword,
315 )
316 );
317
318 $a_xml->xmlData($value);
319 $a_xml->xmlEndTag("ContainerSetting");
320 }
321
322 $a_xml->xmlEndTag("ContainerSettings");
323 }
324 }
325
332 function _lookupIconPath($a_id, $a_size = "big")
333 {
334 if ($a_size == "")
335 {
336 $a_size = "big";
337 }
338 $size = $a_size;
339
340 if (ilContainer::_lookupContainerSetting($a_id, "icon_custom"))
341 {
342 $cont_dir = ilContainer::_getContainerDirectory($a_id);
343
344 $file_name = $cont_dir."/icon_custom.svg";
345 if (is_file($file_name))
346 {
347 return $file_name;
348 }
349 }
350
351 return "";
352 }
353
357 function saveIcons($a_custom_icon)
358 {
359 global $ilDB;
360
362 $cont_dir = $this->getContainerDirectory();
363
364 $file_name = "";
365 if ($a_custom_icon != "")
366 {
367 $file_name = $cont_dir."/icon_custom.svg";
368 ilUtil::moveUploadedFile($a_custom_icon, "icon_custom.svg", $file_name);
369
370 if ($file_name != "" && is_file($file_name))
371 {
372 ilContainer::_writeContainerSetting($this->getId(), "icon_custom", 1);
373 }
374 else
375 {
376 ilContainer::_writeContainerSetting($this->getId(), "icon_custom", 0);
377 }
378 }
379 }
380
385 {
386 $cont_dir = $this->getContainerDirectory();
387 $small_file_name = $cont_dir."/icon_custom.svg";
388 @unlink($small_file_name);
389 ilContainer::_writeContainerSetting($this->getId(), "icon_custom", 0);
390 }
391
400 public function cloneObject($a_target_id,$a_copy_id = 0)
401 {
402 global $ilLog;
403
404 $new_obj = parent::cloneObject($a_target_id,$a_copy_id);
405
406 include_once('./Services/Container/classes/class.ilContainerSortingSettings.php');
407 #18624 - copy all sorting settings
408 ilContainerSortingSettings::_cloneSettings($this->getId(), $new_obj->getId());
409
410 // copy content page
411 include_once("./Services/Container/classes/class.ilContainerPage.php");
412 if (ilContainerPage::_exists("cont",
413 $this->getId()))
414 {
415 $orig_page = new ilContainerPage($this->getId());
416 $orig_page->copy($new_obj->getId(), "cont", $new_obj->getId());
417 }
418
419 // #20614 - copy style
420 include_once("./Services/Style/classes/class.ilObjStyleSheet.php");
421 $style_id = $this->getStyleSheetId();
422 if ($style_id > 0 &&
424 {
425 $style_obj = ilObjectFactory::getInstanceByObjId($style_id);
426 $new_id = $style_obj->ilClone();
427 $new_obj->setStyleSheetId($new_id);
428 $new_obj->update();
429 }
430
431 // #10271 - copy start objects page
432 include_once("./Services/Container/classes/class.ilContainerStartObjectsPage.php");
434 $this->getId()))
435 {
436 $orig_page = new ilContainerStartObjectsPage($this->getId());
437 $orig_page->copy($new_obj->getId(), "cstr", $new_obj->getId());
438 }
439
440 // #10271
441 foreach(self::_getContainerSettings($this->getId()) as $keyword => $value)
442 {
443 self::_writeContainerSetting($new_obj->getId(), $keyword, $value);
444
445 // copy custom icons
446 if($keyword == "icon_custom" &&
447 $value)
448 {
449 // see saveIcons()
450 $new_obj->createContainerDirectory();
451 $tgt_dir = $new_obj->getContainerDirectory();
452 $src_dir = $this->getContainerDirectory();
453 $file = "icon_custom.svg";
454 $src_file = $src_dir."/".$file;
455 if(file_exists($src_file))
456 {
457 copy($src_file, $tgt_dir."/".$file);
458 }
459 }
460 }
461
462 return $new_obj;
463 }
464
473 public function cloneDependencies($a_target_id,$a_copy_id)
474 {
475 global $ilLog;
476
477 parent::cloneDependencies($a_target_id, $a_copy_id);
478
479 include_once('./Services/Container/classes/class.ilContainerSorting.php');
480 ilContainerSorting::_getInstance($this->getId())->cloneSorting($a_target_id,$a_copy_id);
481
482 // fix item group references in page content
483 include_once("./Modules/ItemGroup/classes/class.ilObjItemGroup.php");
485
486 include_once('Services/Object/classes/class.ilObjectLP.php');
487 $olp = ilObjectLP::getInstance($this->getId());
488 $collection = $olp->getCollectionInstance();
489 if($collection)
490 {
491 $collection->cloneCollection($a_target_id, $a_copy_id);
492 }
493
494 return true;
495 }
496
511 public function cloneAllObject($session_id, $client_id, $new_type, $ref_id, $clone_source, $options, $soap_call = false, $a_submode = 1)
512 {
513 global $ilLog;
514
515 include_once('./Services/Link/classes/class.ilLink.php');
516 include_once('Services/CopyWizard/classes/class.ilCopyWizardOptions.php');
517
518 global $ilAccess,$ilErr,$rbacsystem,$tree,$ilUser;
519
520 // Save wizard options
522 $wizard_options = ilCopyWizardOptions::_getInstance($copy_id);
523 $wizard_options->saveOwner($ilUser->getId());
524 $wizard_options->saveRoot($clone_source);
525
526 // add entry for source container
527 $wizard_options->initContainer($clone_source, $ref_id);
528
529 foreach($options as $source_id => $option)
530 {
531 $wizard_options->addEntry($source_id,$option);
532 }
533 $wizard_options->read();
534 $wizard_options->storeTree($clone_source);
535
536 include_once './Services/Object/classes/class.ilObjectCopyGUI.php';
538 {
539 ilLoggerFactory::getLogger('obj')->info('Copy content only...');
540 ilLoggerFactory::getLogger('obj')->debug('Added mapping, source ID: '.$clone_source.', target ID: '.$ref_id);
541 $wizard_options->read();
542 $wizard_options->dropFirstNode();
543 $wizard_options->appendMapping($clone_source,$ref_id);
544 }
545
546
547 #print_r($options);
548 // Duplicate session to avoid logout problems with backgrounded SOAP calls
549 $new_session_id = ilSession::_duplicate($session_id);
550 // Start cloning process using soap call
551 include_once 'Services/WebServices/SOAP/classes/class.ilSoapClient.php';
552
553 $soap_client = new ilSoapClient();
554 $soap_client->setResponseTimeout(5);
555 $soap_client->enableWSDL(true);
556
557 $ilLog->write(__METHOD__.': Trying to call Soap client...');
558 if($soap_client->init())
559 {
560 ilLoggerFactory::getLogger('obj')->info('Calling soap clone method');
561 $res = $soap_client->call('ilClone',array($new_session_id.'::'.$client_id, $copy_id));
562 }
563 else
564 {
565 ilLoggerFactory::getLogger('obj')->warning('SOAP clone call failed. Calling clone method manually');
566 $wizard_options->disableSOAP();
567 $wizard_options->read();
568 include_once('./webservice/soap/include/inc.soap_functions.php');
569 $res = ilSoapFunctions::ilClone($new_session_id.'::'.$client_id, $copy_id);
570 }
571 return array(
572 'copy_id' => $copy_id,
573 'ref_id' => (int) $res
574 );
575 }
576
580 function getViewMode()
581 {
583 }
584
588 function getOrderType()
589 {
590 return $this->order_type ? $this->order_type : ilContainer::SORT_TITLE;
591 }
592
593 function setOrderType($a_value)
594 {
595 $this->order_type = $a_value;
596 }
597
606 function getSubItems($a_admin_panel_enabled = false, $a_include_side_block = false,
607 $a_get_single = 0)
608 {
609 global $objDefinition, $ilBench, $tree, $ilObjDataCache, $ilUser, $rbacsystem,
611
612 // Caching
613 if (is_array($this->items[(int) $a_admin_panel_enabled][(int) $a_include_side_block]) &&
614 !$a_get_single)
615 {
616 return $this->items[(int) $a_admin_panel_enabled][(int) $a_include_side_block];
617 }
618
619 $type_grps = $this->getGroupedObjTypes();
620 $objects = $tree->getChilds($this->getRefId(), "title");
621
622 $objects = self::getCompleteDescriptions($objects);
623
624 $found = false;
625 $all_ref_ids = array();
626
627 if(!self::$data_preloaded)
628 {
629 include_once("./Services/Object/classes/class.ilObjectListGUIPreloader.php");
631 }
632
633 include_once('Services/Container/classes/class.ilContainerSorting.php');
634 $sort = ilContainerSorting::_getInstance($this->getId());
635
636 // TODO: check this
637 // get items attached to a session
638 include_once './Modules/Session/classes/class.ilEventItems.php';
639 $event_items = ilEventItems::_getItemsOfContainer($this->getRefId());
640
641 foreach ($objects as $key => $object)
642 {
643 if ($a_get_single > 0 && $object["child"] != $a_get_single)
644 {
645 continue;
646 }
647
648 // hide object types in devmode
649 if ($objDefinition->getDevMode($object["type"]) || $object["type"] == "adm"
650 || $object["type"] == "rolf")
651 {
652 continue;
653 }
654
655 // remove inactive plugins
656 if ($objDefinition->isInactivePlugin($object["type"]))
657 {
658 continue;
659 }
660
661 // BEGIN WebDAV: Don't display hidden Files, Folders and Categories
662 if (in_array($object['type'], array('file','fold','cat')))
663 {
664 include_once 'Modules/File/classes/class.ilObjFileAccess.php';
665 if (ilObjFileAccess::_isFileHidden($object['title']))
666 {
667 $this->setHiddenFilesFound(true);
668 if (!$a_admin_panel_enabled)
669 {
670 continue;
671 }
672 }
673 }
674 // END WebDAV: Don't display hidden Files, Folders and Categories
675
676 // including event items!
677 if (!self::$data_preloaded)
678 {
679 $preloader->addItem($object["obj_id"], $object["type"], $object["child"]);
680 }
681
682 // filter out items that are attached to an event
683 if (in_array($object['ref_id'],$event_items))
684 {
685 continue;
686 }
687
688 // filter side block items
689 if(!$a_include_side_block && $objDefinition->isSideBlock($object['type']))
690 {
691 continue;
692 }
693
694 $all_ref_ids[] = $object["child"];
695 }
696
697 // data preloader
698 if (!self::$data_preloaded)
699 {
700 $preloader->preload();
701 unset($preloader);
702
703 self::$data_preloaded = true;
704 }
705
706 foreach($objects as $key => $object)
707 {
708 // see above, objects were filtered
709 if(!in_array($object["child"], $all_ref_ids))
710 {
711 continue;
712 }
713
714 // group object type groups together (e.g. learning resources)
715 $type = $objDefinition->getGroupOfObj($object["type"]);
716 if ($type == "")
717 {
718 $type = $object["type"];
719 }
720
721 // this will add activation properties
722 $this->addAdditionalSubItemInformation($object);
723
724 $this->items[$type][$key] = $object;
725
726 $this->items["_all"][$key] = $object;
727 if ($object["type"] != "sess")
728 {
729 $this->items["_non_sess"][$key] = $object;
730 }
731 }
732
733 $this->items[(int) $a_admin_panel_enabled][(int) $a_include_side_block]
734 = $sort->sortItems($this->items);
735
736 return $this->items[(int) $a_admin_panel_enabled][(int) $a_include_side_block];
737 }
738
742 function gotItems()
743 {
744 if (is_array($this->items["_all"]) && count($this->items["_all"]) > 0)
745 {
746 return true;
747 }
748 return false;
749 }
750
756 {
757 }
758
765 {
766 global $objDefinition;
767
768 if (empty($this->type_grps))
769 {
770 $this->type_grps = $objDefinition->getGroupedRepositoryObjectTypes($this->getType());
771 }
772 return $this->type_grps;
773 }
774
779 {
780 global $ilSetting;
781
782 // @todo: this will need a more general approach
783 if ($ilSetting->get("enable_cat_page_edit"))
784 {
785 return true;
786 }
787 }
788
792 function create()
793 {
794 $ret = parent::create();
795
796 if (((int) $this->getStyleSheetId()) > 0)
797 {
798 include_once("./Services/Style/classes/class.ilObjStyleSheet.php");
800 }
801
802 return $ret;
803 }
804
808 function update()
809 {
810 $ret = parent::update();
811
812 include_once("./Services/Style/classes/class.ilObjStyleSheet.php");
814
815 return $ret;
816 }
817
818
826 public function read()
827 {
828 parent::read();
829
830 include_once("./Services/Container/classes/class.ilContainerSortingSettings.php");
832
833 include_once("./Services/Style/classes/class.ilObjStyleSheet.php");
835 }
836
844 public static function getCompleteDescriptions(array $objects)
845 {
846 global $ilSetting, $ilObjDataCache;
847 // using long descriptions?
848 $short_desc = $ilSetting->get("rep_shorten_description");
849 $short_desc_max_length = $ilSetting->get("rep_shorten_description_length");
850 if(!$short_desc || $short_desc_max_length != ilObject::DESC_LENGTH)
851 {
852 // using (part of) shortened description
853 if($short_desc && $short_desc_max_length && $short_desc_max_length < ilObject::DESC_LENGTH)
854 {
855 foreach($objects as $key => $object)
856 {
857 $objects[$key]["description"] = ilUtil::shortenText($object["description"], $short_desc_max_length, true);
858 }
859 }
860 // using (part of) long description
861 else
862 {
863 $obj_ids = array();
864 foreach($objects as $key => $object)
865 {
866 $obj_ids[] = $object["obj_id"];
867 }
868 if(sizeof($obj_ids))
869 {
871 foreach($objects as $key => $object)
872 {
873 // #12166 - keep translation, ignore long description
874 if($ilObjDataCache->isTranslatedDescription($object["obj_id"]))
875 {
876 $long_desc[$object["obj_id"]] = $object["description"];
877 }
878 if($short_desc && $short_desc_max_length)
879 {
880 $long_desc[$object["obj_id"]] = ilUtil::shortenText($long_desc[$object["obj_id"]], $short_desc_max_length, true);
881 }
882 $objects[$key]["description"] = $long_desc[$object["obj_id"]];
883 }
884 }
885 }
886 }
887 return $objects;
888 }
889
890} // END class ilContainer
891?>
print $file
$size
Definition: RandomTest.php:79
const DB_FETCHMODE_ASSOC
Definition: class.ilDB.php:10
Container page object.
static _cloneSettings($a_old_id, $a_new_id)
Clone settings.
static _lookupSortMode($a_obj_id)
lookup sort mode
static _getInstance($a_obj_id)
get instance by obj_id
Container start objects page object.
Class ilContainer.
_lookupIconPath($a_id, $a_size="big")
lookup icon path
const SORT_DIRECTION_DESC
saveIcons($a_custom_icon)
save container icons
cloneDependencies($a_target_id, $a_copy_id)
Clone object dependencies (container sorting)
static $data_preloaded
getGroupedObjTypes()
Get grouped repository object types.
cloneAllObject($session_id, $client_id, $new_type, $ref_id, $clone_source, $options, $soap_call=false, $a_submode=1)
clone all objects according to this container
getSubItems($a_admin_panel_enabled=false, $a_include_side_block=false, $a_get_single=0)
Get subitems of container.
getStyleSheetId()
get ID of assigned style sheet object
static _exportContainerSettings(ilXmlWriter $a_xml, $a_obj_id)
static getCompleteDescriptions(array $objects)
overwrites description fields to long or short description in an assoc array keys needed (obj_id and ...
static _deleteContainerSettings($a_id, $a_keyword=null, $a_keyword_like=false)
const SORT_NEW_ITEMS_ORDER_ACTIVATION
getBigIconPath()
Get path for big icon.
getContainerDirectory()
Get the container directory.
getCustomIconPath()
Get path for custom icon.
createContainerDirectory()
Create directory for the container.
setHiddenFilesFound($a_hiddenfilesfound)
Set Found hidden files (set by getSubItems).
addAdditionalSubItemInformation(&$object)
Add additional information to sub item, e.g.
static _getContainerSettings($a_id)
const SORT_NEW_ITEMS_ORDER_TITLE
_lookupContainerSetting($a_id, $a_keyword, $a_default_value=NULL)
Lookup a container setting.
setOrderType($a_value)
getHiddenFilesFound()
Get Found hidden files (set by getSubItems).
_getContainerDirectory($a_id)
Get the container directory.
setStyleSheetId($a_style_id)
set ID of assigned style sheet object
const SORT_NEW_ITEMS_ORDER_CREATION
_writeContainerSetting($a_id, $a_keyword, $a_value)
getSmallIconPath()
Get path for small icon.
const SORT_NEW_ITEMS_POSITION_BOTTOM
removeCustomIcon()
remove small icon
getOrderType()
Get order type default implementation.
const SORT_NEW_ITEMS_POSITION_TOP
ilContainer($a_id=0, $a_call_by_reference=true)
Constructor @access public.
const SORT_DIRECTION_ASC
gotItems()
Check whether we got any items.
getViewMode()
Get container view mode.
enablePageEditing()
Check whether page editing is allowed for container.
cloneObject($a_target_id, $a_copy_id=0)
Clone container settings.
getTinyIconPath()
Get path for tiny icon.
static _allocateCopyId()
Allocate a copy for further entries.
static _getInstance($a_copy_id)
Get instance of copy wizard options.
_getItemsOfContainer($a_ref_id)
static getLogger($a_component_id)
Get component logger.
static _isFileHidden($a_file_name)
Returns true, if a file with the specified name, is usually hidden from the user.
static fixContainerItemGroupRefsAfterCloning($a_source_container, $a_copy_id)
Fix container item group references after a container has been cloned.
static lookupObjectStyle($a_obj_id)
Lookup object style.
static writeStyleUsage($a_obj_id, $a_style_id)
Write style usage.
_lookupStandard($a_id)
Lookup standard flag.
getInstanceByObjId($a_obj_id, $stop_on_error=true)
get an instance of an Ilias object by object id
static getInstance($a_obj_id)
Preloader for object list GUIs.
Class ilObject Basic functions for all objects.
getType()
get object type @access public
getRefId()
get reference id @access public
getId()
get object id @access public
const DESC_LENGTH
static getLongDescriptions(array $a_obj_ids)
Get long description data.
static _exists($a_parent_type, $a_id, $a_lang="", $a_no_cache=false)
Checks whether page exists.
static _duplicate($a_session_id)
Duplicate session.
static ilClone($sid, $copy_identifier)
static moveUploadedFile($a_file, $a_name, $a_target, $a_raise_errors=true, $a_mode="move_uploaded")
move uploaded file
static shortenText($a_str, $a_len, $a_dots=false, $a_next_blank=false, $a_keep_extension=false)
shorten a string to given length.
static getWebspaceDir($mode="filesystem")
get webspace directory
static makeDir($a_dir)
creates a new directory and inherits all filesystem permissions of the parent directory You may pass ...
XML writer class.
xmlEndTag($tag)
Writes an endtag.
xmlData($data, $encode=TRUE, $escape=TRUE)
Writes data.
xmlStartTag($tag, $attrs=NULL, $empty=FALSE, $encode=TRUE, $escape=TRUE)
Writes a starttag.
global $ilBench
Definition: ilias.php:18
$client_id
global $ilSetting
Definition: privfeed.php:40
global $ilDB
if(!is_array($argv)) $options
global $ilUser
Definition: imgupload.php:15