ILIAS  release_8 Revision v8.24
ilObjWiki Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Inheritance diagram for ilObjWiki:
+ Collaboration diagram for ilObjWiki:

Public Member Functions

 __construct (int $a_id=0, bool $a_call_by_reference=true)
 
 setOnline (bool $a_online)
 
 getOnline ()
 
 setRatingOverall (bool $a_rating)
 
 getRatingOverall ()
 
 setRating (bool $a_rating)
 
 getRating ()
 
 setRatingAsBlock (bool $a_rating)
 
 getRatingAsBlock ()
 
 setRatingForNewPages (bool $a_rating)
 
 getRatingForNewPages ()
 
 setRatingCategories (bool $a_rating)
 
 getRatingCategories ()
 
 setPublicNotes (bool $a_val)
 
 getPublicNotes ()
 
 setStartPage (string $a_startpage)
 
 getStartPage ()
 
 setShortTitle (string $a_shorttitle)
 
 getShortTitle ()
 
 setIntroduction (string $a_introduction)
 
 getIntroduction ()
 
 setPageToc (bool $a_val)
 
 getPageToc ()
 
 setEmptyPageTemplate (bool $a_val)
 
 getEmptyPageTemplate ()
 
 setLinkMetadataValues (bool $a_val)
 
 getLinkMetadataValues ()
 
 create (bool $a_prevent_start_page_creation=false)
 
 update (bool $a_prevent_start_page_creation=false)
 
 read ()
 
 delete ()
 delete object and all related data More...
 
 addImportantPage (int $a_page_id, int $a_nr=0, int $a_indent=0)
 
 isImportantPage (int $a_page_id)
 
 removeImportantPage (int $a_id)
 
 saveOrderingAndIndentation (array $a_ord, array $a_indent)
 
 fixImportantPagesNumbering ()
 
 cloneObject (int $target_id, int $copy_id=0, bool $omit_tree=false)
 
 getTemplateSelectionOnCreation ()
 Get template selection on creation? If more than one template (including empty page template) is activated -> return true. More...
 
 createWikiPage (string $a_page_title, int $a_template_page=0)
 Create new wiki page. More...
 
 initUserHTMLExport (bool $with_comments=false)
 
 startUserHTMLExport (bool $with_comments=false)
 
 getUserHTMLExportProgress (bool $with_comments=false)
 Get user html export progress. More...
 
 deliverUserHTMLExport (bool $with_comments=false)
 
 decorateAdvMDValue (string $a_value)
 Decorate adv md value. More...
 
 isCommentsExportPossible ()
 Is export possible. More...
 
- Public Member Functions inherited from ilObject
 __construct (int $id=0, bool $reference=true)
 
 withReferences ()
 determines whether objects are referenced or not (got ref ids or not) More...
 
 processAutoRating ()
 
 read ()
 
 getId ()
 
 setId (int $id)
 
 setRefId (int $ref_id)
 
 getRefId ()
 
 getType ()
 
 setType (string $type)
 
 getPresentationTitle ()
 get presentation title Normally same as title Overwritten for sessions More...
 
 getTitle ()
 
 getUntranslatedTitle ()
 Get untranslated object title WebDAV needs to access the untranslated title of an object. More...
 
 setTitle (string $title)
 
 getDescription ()
 
 setDescription (string $desc)
 
 getLongDescription ()
 get object long description (stored in object_description) More...
 
 getImportId ()
 
 setImportId (string $import_id)
 
 setOfflineStatus (bool $status)
 
 getOfflineStatus ()
 
 supportsOfflineHandling ()
 
 getOwner ()
 
 getOwnerName ()
 get full name of object owner More...
 
 setOwner (int $usr_id)
 
 getCreateDate ()
 Get create date in YYYY-MM-DD HH-MM-SS format. More...
 
 getLastUpdateDate ()
 Get last update date in YYYY-MM-DD HH-MM-SS format. More...
 
 create ()
 note: title, description and type should be set when this function is called More...
 
 update ()
 
 MDUpdateListener (string $element)
 Metadata update listener. More...
 
 createMetaData ()
 
 updateMetaData ()
 
 deleteMetaData ()
 
 updateOwner ()
 update owner of object in db More...
 
 putInTree (int $parent_ref_id)
 maybe this method should be in tree object!? More...
 
 setPermissions (int $parent_ref_id)
 
 setParentRolePermissions (int $parent_ref_id)
 Initialize the permissions of parent roles (local roles of categories, global roles...) This method is overwritten in e.g. More...
 
 createReference ()
 creates reference for object More...
 
 countReferences ()
 
 delete ()
 delete object or referenced object (in the case of a referenced object, object data is only deleted if last reference is deleted) This function removes an object entirely from system!! More...
 
 initDefaultRoles ()
 init default roles settings Purpose of this function is to create a local role folder and local roles, that are needed depending on the object type. More...
 
 applyDidacticTemplate (int $tpl_id)
 
 getXMLZip ()
 
 getHTMLDirectory ()
 
 appendCopyInfo (int $target_id, int $copy_id)
 Prepend Copy info if object with same name exists in that container. More...
 
 cloneDependencies (int $target_id, int $copy_id)
 Clone object dependencies. More...
 
 cloneMetaData (ilObject $target_obj)
 Copy meta data. More...
 
 selfOrParentWithRatingEnabled ()
 
 getPossibleSubObjects (bool $filter=true)
 get all possible sub objects of this type the object can decide which types of sub objects are possible jut in time overwrite if the decision distinguish from standard model More...
 

Static Public Member Functions

static checkShortTitleAvailability (string $a_short_title)
 
static _lookupRatingOverall (int $a_wiki_id)
 Lookup whether rating is activated for whole object. More...
 
static _lookupRating (int $a_wiki_id)
 Lookup whether rating is activated. More...
 
static _lookupRatingCategories (int $a_wiki_id)
 Lookup whether rating categories are activated. More...
 
static _lookupRatingAsBlock (int $a_wiki_id)
 Lookup whether rating side block is activated. More...
 
static _lookupPublicNotes (int $a_wiki_id)
 Lookup whether public notes are activated. More...
 
static _lookupLinkMetadataValues (int $a_wiki_id)
 Lookup whether metadata should be auto linked. More...
 
static _lookupStartPage (int $a_wiki_id)
 
static writeStartPage (int $a_id, string $a_name)
 
static _performSearch (int $a_wiki_id, string $a_searchterm)
 Search in Wiki. More...
 
static _lookupImportantPagesList (int $a_wiki_id)
 
static _lookupMaxOrdNrImportantPages (int $a_wiki_id)
 
static _lookupPageToc (int $a_wiki_id)
 
static getAdvMDSubItemTitle (int $a_obj_id, string $a_sub_type, int $a_sub_id)
 
- Static Public Member Functions inherited from ilObject
static _lookupObjIdByImportId (string $import_id)
 Get (latest) object id for an import id. More...
 
static _lookupImportId (int $obj_id)
 
static _lookupOwnerName (int $owner_id)
 Lookup owner name for owner id. More...
 
static _getIdForImportId (string $import_id)
 
static _getAllReferences (int $id)
 get all reference ids for object ID More...
 
static _lookupTitle (int $obj_id)
 
static lookupOfflineStatus (int $obj_id)
 Lookup offline status using objectDataCache. More...
 
static _lookupOwner (int $obj_id)
 Lookup owner user ID for object ID. More...
 
static _getIdsForTitle (string $title, string $type='', bool $partial_match=false)
 
static _lookupDescription (int $obj_id)
 
static _lookupLastUpdate (int $obj_id, bool $formatted=false)
 
static _getLastUpdateOfObjects (array $obj_ids)
 
static _lookupObjId (int $ref_id)
 
static _setDeletedDate (int $ref_id, int $deleted_by)
 
static setDeletedDates (array $ref_ids, int $user_id)
 
static _resetDeletedDate (int $ref_id)
 
static _lookupDeletedDate (int $ref_id)
 
static _writeTitle (int $obj_id, string $title)
 write title to db (static) More...
 
static _writeDescription (int $obj_id, string $desc)
 write description to db (static) More...
 
static _writeImportId (int $obj_id, string $import_id)
 write import id to db (static) More...
 
static _lookupType (int $id, bool $reference=false)
 
static _isInTrash (int $ref_id)
 
static _hasUntrashedReference (int $obj_id)
 checks whether an object has at least one reference that is not in trash More...
 
static _lookupObjectId (int $ref_id)
 
static _getObjectsDataForType (string $type, bool $omit_trash=false)
 get all objects of a certain type More...
 
static _exists (int $id, bool $reference=false, ?string $type=null)
 checks if an object exists in object_data More...
 
static _getObjectsByType (string $obj_type="", int $owner=null)
 
static _prepareCloneSelection (array $ref_ids, string $new_type, bool $show_path=true)
 Prepare copy wizard object selection. More...
 
static _getIcon (int $obj_id=0, string $size="big", string $type="", bool $offline=false)
 Get icon for repository item. More...
 
static collectDeletionDependencies (array &$deps, int $ref_id, int $obj_id, string $type, int $depth=0)
 Collect deletion dependencies. More...
 
static getDeletionDependencies (int $obj_id)
 Get deletion dependencies. More...
 
static getLongDescriptions (array $obj_ids)
 
static getAllOwnedRepositoryObjects (int $user_id)
 
static fixMissingTitles ($type, array &$obj_title_map)
 Try to fix missing object titles. More...
 
static _lookupCreationDate (int $obj_id)
 
static _getObjectTypeIdByTitle (string $type, \ilDBInterface $ilDB=null)
 
static getAdvMDSubItemTitle (int $a_obj_id, string $a_sub_type, int $a_sub_id)
 

Protected Member Functions

 updateInternalLinksOnCopy (array $map)
 
- Protected Member Functions inherited from ilObject
 doMDUpdateListener (string $a_element)
 
 beforeMDUpdateListener (string $a_element)
 
 doCreateMetaData ()
 
 beforeCreateMetaData ()
 
 doUpdateMetaData ()
 
 beforeUpdateMetaData ()
 
 doDeleteMetaData ()
 
 beforeDeleteMetaData ()
 
 handleAutoRating ()
 
 hasAutoRating ()
 

Protected Attributes

bool $page_toc = false
 
int $style_id = 0
 
string $introduction = ""
 
string $shorttitle = ""
 
string $startpage = ""
 
bool $rating_categories = false
 
bool $rating_new_pages = false
 
bool $rating = false
 
bool $rating_block = false
 
bool $rating_overall = false
 
ilObjUser $user
 
bool $online = false
 
bool $public_notes = true
 
bool $empty_page_templ = true
 
bool $link_md_values = false
 
ilSetting $setting
 
ILIAS Style Content DomainService $content_style_service
 
- Protected Attributes inherited from ilObject
ilLogger $obj_log
 
ILIAS $ilias
 
ilObjectDefinition $obj_definition
 
ilDBInterface $db
 
ilLogger $log
 
ilErrorHandling $error
 
ilTree $tree
 
ilAppEventHandler $app_event_handler
 
ilRbacAdmin $rbac_admin
 
ilRbacReview $rbac_review
 
ilObjUser $user
 
ilLanguage $lng
 
int $id
 
bool $referenced
 
bool $call_by_reference
 
int $max_title = self::TITLE_LENGTH
 
int $max_desc = self::DESC_LENGTH
 
bool $add_dots = true
 
int $ref_id = null
 
string $type = ""
 
string $title = ""
 
bool $offline = false
 
string $desc = ""
 
string $long_desc = ""
 
int $owner = 0
 
string $create_date = ""
 
string $last_update = ""
 
string $import_id = ""
 
bool $register = false
 

Static Private Member Functions

static _lookup (int $a_wiki_id, string $a_field)
 Lookup a data field. More...
 

Additional Inherited Members

- Data Fields inherited from ilObject
const TITLE_LENGTH = 255
 
const DESC_LENGTH = 128
 
const LONG_DESC_LENGTH = 4000
 
const TABLE_OBJECT_DATA = "object_data"
 
array $objectList
 
string $untranslatedTitle
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Class ilObjWiki

Author
Alexander Killing killi.nosp@m.ng@l.nosp@m.eifos.nosp@m..de

Definition at line 24 of file class.ilObjWiki.php.

Constructor & Destructor Documentation

◆ __construct()

ilObjWiki::__construct ( int  $id = 0,
bool  $reference = true 
)
Parameters
int$idreference_id or object_id
bool$referencebool treat the id as reference_id (true) or object_id (false)

Reimplemented from ilObject.

Definition at line 44 of file class.ilObjWiki.php.

47 {
48 global $DIC;
49
50 $this->db = $DIC->database();
51 $this->user = $DIC->user();
52 $this->type = "wiki";
53 $this->setting = $DIC->settings();
54 parent::__construct($a_id, $a_call_by_reference);
55
56 $this->content_style_service = $DIC
57 ->contentStyle()
58 ->domain();
59 }
global $DIC
Definition: feed.php:28
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc

References $DIC, ILIAS\GlobalScreen\Provider\__construct(), and ILIAS\Repository\user().

+ Here is the call graph for this function:

Member Function Documentation

◆ _lookup()

static ilObjWiki::_lookup ( int  $a_wiki_id,
string  $a_field 
)
staticprivate

Lookup a data field.

Returns
mixed

Definition at line 386 of file class.ilObjWiki.php.

387 {
388 global $DIC;
389
390 $ilDB = $DIC->database();
391
392 $query = "SELECT $a_field FROM il_wiki_data WHERE id = " .
393 $ilDB->quote($a_wiki_id, "integer");
394 $set = $ilDB->query($query);
395 $rec = $ilDB->fetchAssoc($set);
396 return $rec[$a_field] ?? null;
397 }
$query

References $DIC, $ilDB, and $query.

◆ _lookupImportantPagesList()

static ilObjWiki::_lookupImportantPagesList ( int  $a_wiki_id)
static

Definition at line 454 of file class.ilObjWiki.php.

454 : array
455 {
456 global $DIC;
457
458 $ilDB = $DIC->database();
459
460 $set = $ilDB->query(
461 "SELECT * FROM il_wiki_imp_pages WHERE " .
462 " wiki_id = " . $ilDB->quote($a_wiki_id, "integer") . " ORDER BY ord ASC "
463 );
464
465 $imp_pages = array();
466
467 while ($rec = $ilDB->fetchAssoc($set)) {
468 $imp_pages[] = $rec;
469 }
470 return $imp_pages;
471 }

References $DIC, and $ilDB.

Referenced by ilImportantPagesTableGUI\__construct(), ilObjWikiGUI\editImportantPagesObject(), and ilWikiImportantPagesBlockGUI\getLegacyContent().

+ Here is the caller graph for this function:

◆ _lookupLinkMetadataValues()

static ilObjWiki::_lookupLinkMetadataValues ( int  $a_wiki_id)
static

Lookup whether metadata should be auto linked.

Definition at line 377 of file class.ilObjWiki.php.

377 : bool
378 {
379 return (bool) self::_lookup($a_wiki_id, "link_md_values");
380 }
static _lookup(int $a_wiki_id, string $a_field)
Lookup a data field.

◆ _lookupMaxOrdNrImportantPages()

static ilObjWiki::_lookupMaxOrdNrImportantPages ( int  $a_wiki_id)
static

Definition at line 473 of file class.ilObjWiki.php.

475 : int {
476 global $DIC;
477
478 $ilDB = $DIC->database();
479
480 $set = $ilDB->query(
481 "SELECT MAX(ord) as m FROM il_wiki_imp_pages WHERE " .
482 " wiki_id = " . $ilDB->quote($a_wiki_id, "integer")
483 );
484
485 $rec = $ilDB->fetchAssoc($set);
486 return (int) $rec["m"];
487 }

◆ _lookupPageToc()

static ilObjWiki::_lookupPageToc ( int  $a_wiki_id)
static

Definition at line 619 of file class.ilObjWiki.php.

621 : bool {
622 return (bool) self::_lookup($a_wiki_id, "page_toc");
623 }

Referenced by ilWikiPageConfig\configureByObjectId().

+ Here is the caller graph for this function:

◆ _lookupPublicNotes()

static ilObjWiki::_lookupPublicNotes ( int  $a_wiki_id)
static

Lookup whether public notes are activated.

Definition at line 369 of file class.ilObjWiki.php.

369 : bool
370 {
371 return (bool) self::_lookup($a_wiki_id, "public_notes");
372 }

Referenced by ilWikiPageGUI\getCommentsHTMLExport(), and ilWikiPageGUI\preview().

+ Here is the caller graph for this function:

◆ _lookupRating()

static ilObjWiki::_lookupRating ( int  $a_wiki_id)
static

Lookup whether rating is activated.

Definition at line 345 of file class.ilObjWiki.php.

345 : bool
346 {
347 return (bool) self::_lookup($a_wiki_id, "rating");
348 }

Referenced by ilWikiFunctionsBlockGUI\getLegacyContent().

+ Here is the caller graph for this function:

◆ _lookupRatingAsBlock()

static ilObjWiki::_lookupRatingAsBlock ( int  $a_wiki_id)
static

Lookup whether rating side block is activated.

Definition at line 361 of file class.ilObjWiki.php.

361 : bool
362 {
363 return (bool) self::_lookup($a_wiki_id, "rating_side");
364 }

◆ _lookupRatingCategories()

static ilObjWiki::_lookupRatingCategories ( int  $a_wiki_id)
static

Lookup whether rating categories are activated.

Definition at line 353 of file class.ilObjWiki.php.

353 : bool
354 {
355 return (bool) self::_lookup($a_wiki_id, "rating_ext");
356 }

◆ _lookupRatingOverall()

static ilObjWiki::_lookupRatingOverall ( int  $a_wiki_id)
static

Lookup whether rating is activated for whole object.

Definition at line 337 of file class.ilObjWiki.php.

337 : bool
338 {
339 return (bool) self::_lookup($a_wiki_id, "rating_overall");
340 }

◆ _lookupStartPage()

static ilObjWiki::_lookupStartPage ( int  $a_wiki_id)
static

Definition at line 399 of file class.ilObjWiki.php.

399 : string
400 {
401 return (string) self::_lookup($a_wiki_id, "startpage");
402 }

Referenced by ilWikiHandlerGUI\executeCommand(), ilObjWikiGUI\getGotoLink(), ilWikiFunctionsBlockGUI\getLegacyContent(), and ilWikiImportantPagesBlockGUI\getLegacyContent().

+ Here is the caller graph for this function:

◆ _performSearch()

static ilObjWiki::_performSearch ( int  $a_wiki_id,
string  $a_searchterm 
)
static

Search in Wiki.

Definition at line 420 of file class.ilObjWiki.php.

423 : array {
424 // query parser
425 $query_parser = new ilQueryParser($a_searchterm);
426 $query_parser->setCombination("or");
427 $query_parser->parse();
428
429 $search_result = new ilSearchResult();
430 if ($query_parser->validate()) {
431 $wiki_search = ilObjectSearchFactory::_getWikiContentSearchInstance($query_parser);
432 $wiki_search->setFilter(array('wpg'));
433 $r = $wiki_search->performSearch();
434 $search_result->mergeEntries($r);
435 }
436
437 $entries = $search_result->getEntries();
438
439 $found_pages = array();
440 foreach ($entries as $entry) {
441 if ($entry["obj_id"] == $a_wiki_id && is_array($entry["child"])) {
442 foreach ($entry["child"] as $child) {
443 $found_pages[] = array("page_id" => $child);
444 }
445 }
446 }
447 return $found_pages;
448 }
static _getWikiContentSearchInstance(ilQueryParser $query_parser)

Referenced by ilObjWikiGUI\performSearchObject(), and ilWikiPageGUI\searchWikiLinkAC().

+ Here is the caller graph for this function:

◆ addImportantPage()

ilObjWiki::addImportantPage ( int  $a_page_id,
int  $a_nr = 0,
int  $a_indent = 0 
)

Definition at line 490 of file class.ilObjWiki.php.

494 : void {
496
497 if (!$this->isImportantPage($a_page_id)) {
498 if ($a_nr === 0) {
499 $a_nr = self::_lookupMaxOrdNrImportantPages($this->getId()) + 10;
500 }
501
502 $ilDB->manipulate("INSERT INTO il_wiki_imp_pages " .
503 "(wiki_id, ord, indent, page_id) VALUES (" .
504 $ilDB->quote($this->getId(), "integer") . "," .
505 $ilDB->quote($a_nr, "integer") . "," .
506 $ilDB->quote($a_indent, "integer") . "," .
507 $ilDB->quote($a_page_id, "integer") .
508 ")");
509 }
510 }
isImportantPage(int $a_page_id)
static _lookupMaxOrdNrImportantPages(int $a_wiki_id)
ilDBInterface $db

References $ilDB, and ILIAS\Survey\Mode\getId().

+ Here is the call graph for this function:

◆ checkShortTitleAvailability()

static ilObjWiki::checkShortTitleAvailability ( string  $a_short_title)
static

Definition at line 313 of file class.ilObjWiki.php.

315 : bool {
316 global $DIC;
317 $ilDB = $DIC->database();
318
319 if ($a_short_title === "") {
320 return true;
321 }
322 $res = $ilDB->queryF(
323 "SELECT id FROM il_wiki_data WHERE short = %s",
324 array("text"),
325 array($a_short_title)
326 );
327 if ($ilDB->fetchAssoc($res)) {
328 return false;
329 }
330
331 return true;
332 }
$res
Definition: ltiservices.php:69

Referenced by ilObjWikiGUI\saveObject(), and ilObjWikiGUI\saveSettingsObject().

+ Here is the caller graph for this function:

◆ cloneObject()

ilObjWiki::cloneObject ( int  $target_id,
int  $copy_id = 0,
bool  $omit_tree = false 
)

Definition at line 625 of file class.ilObjWiki.php.

625 : ?ilObject
626 {
627 $new_obj = parent::cloneObject($target_id, $copy_id, $omit_tree);
628
629 // Custom meta data activation is stored in a container setting
631 $new_obj->getId(),
634 $this->getId(),
636 0
637 )
638 );
639
640 //copy online status if object is not the root copy object
641 $cp_options = ilCopyWizardOptions::_getInstance($copy_id);
642
643 if (!$cp_options->isRootNode($this->getRefId())) {
644 $new_obj->setOnline($this->getOnline());
645 }
646
647 //$new_obj->setTitle($this->getTitle()); // see #20074
648 $new_obj->setStartPage($this->getStartPage());
649 $new_obj->setShortTitle($this->getShortTitle());
650 $new_obj->setRatingOverall($this->getRatingOverall());
651 $new_obj->setRating($this->getRating());
652 $new_obj->setRatingAsBlock($this->getRatingAsBlock());
653 $new_obj->setRatingForNewPages($this->getRatingForNewPages());
654 $new_obj->setRatingCategories($this->getRatingCategories());
655 $new_obj->setPublicNotes($this->getPublicNotes());
656 $new_obj->setIntroduction($this->getIntroduction());
657 $new_obj->setPageToc($this->getPageToc());
658 $new_obj->update();
659
660 $this->content_style_service
661 ->styleForRefId($this->getRefId())
662 ->cloneTo($new_obj->getId());
663
664 // copy content
665 $pages = ilWikiPage::getAllWikiPages($this->getId());
666 if (count($pages) > 0) {
667 // if we have any pages, delete the start page first
668 $pg_id = ilWikiPage::getPageIdForTitle($new_obj->getId(), $new_obj->getStartPage());
669 $start_page = new ilWikiPage($pg_id);
670 $start_page->delete();
671 }
672 $map = array();
673 foreach ($pages as $p) {
674 $page = new ilWikiPage($p["id"]);
675 $new_page = new ilWikiPage();
676 $new_page->setTitle($page->getTitle());
677 $new_page->setWikiId($new_obj->getId());
678 $new_page->setTitle($page->getTitle());
679 $new_page->setBlocked($page->getBlocked());
680 $new_page->setRating($page->getRating());
681 $new_page->hideAdvancedMetadata($page->isAdvancedMetadataHidden());
682 $new_page->create();
683
684 $page->copy($new_page->getId(), "", 0, true);
685 //$new_page->setXMLContent($page->copyXMLContent(true));
686 //$new_page->buildDom(true);
687 //$new_page->update();
688 $map[$p["id"]] = $new_page->getId();
689
691 $copy_id,
692 $this->getId(),
693 $new_obj->getId(),
694 "wpg",
695 (int) $p["id"],
696 $new_page->getId(),
697 );
698 }
699
700 // copy important pages
701 foreach (self::_lookupImportantPagesList($this->getId()) as $ip) {
702 $new_obj->addImportantPage($map[$ip["page_id"]], $ip["ord"], $ip["indent"]);
703 }
704 $this->updateInternalLinksOnCopy($map);
705
706 // copy rating categories
707 foreach (ilRatingCategory::getAllForObject($this->getId()) as $rc) {
708 $new_rc = new ilRatingCategory();
709 $new_rc->setParentId($new_obj->getId());
710 $new_rc->setTitle((string) $rc["title"]);
711 $new_rc->setDescription((string) $rc["description"]);
712 $new_rc->save();
713 }
714
715 return $new_obj;
716 }
static _cloneValues(int $copy_id, int $a_source_id, int $a_target_id, ?string $a_sub_type=null, ?int $a_source_sub_id=null, ?int $a_target_sub_id=null)
Clone Advanced Meta Data.
static _writeContainerSetting(int $a_id, string $a_keyword, string $a_value)
static _lookupContainerSetting(int $a_id, string $a_keyword, string $a_default_value=null)
static _getInstance(int $a_copy_id)
updateInternalLinksOnCopy(array $map)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
static getAllForObject(int $a_parent_obj_id)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
static getAllWikiPages(int $a_wiki_id)
static getPageIdForTitle(int $a_wiki_id, string $a_title)
Get wiki page object for id and title.
$target_id
Definition: goto.php:52

References $target_id, ilAdvancedMDValues\_cloneValues(), ilCopyWizardOptions\_getInstance(), ilContainer\_lookupContainerSetting(), ilContainer\_writeContainerSetting(), ilObjectServiceSettingsGUI\CUSTOM_METADATA, ilRatingCategory\getAllForObject(), ilWikiPage\getAllWikiPages(), ILIAS\Survey\Mode\getId(), and ilWikiPage\getPageIdForTitle().

+ Here is the call graph for this function:

◆ create()

ilObjWiki::create ( bool  $a_prevent_start_page_creation = false)

Definition at line 193 of file class.ilObjWiki.php.

195 : int {
197
198 $id = parent::create();
199
200 $ilDB->insert("il_wiki_data", array(
201 "id" => array("integer", $this->getId()),
202 "is_online" => array("integer", (int) $this->getOnline()),
203 "startpage" => array("text", $this->getStartPage()),
204 "short" => array("text", $this->getShortTitle()),
205 "rating" => array("integer", (int) $this->getRating()),
206 "public_notes" => array("integer", (int) $this->getPublicNotes()),
207 "introduction" => array("clob", $this->getIntroduction()),
208 "empty_page_templ" => array("integer", (int) $this->getEmptyPageTemplate()),
209 ));
210
211 // create start page
212 if ($this->getStartPage() !== "" && !$a_prevent_start_page_creation) {
213 $start_page = new ilWikiPage();
214 $start_page->setWikiId($this->getId());
215 $start_page->setTitle($this->getStartPage());
216 $start_page->create();
217 }
218
219 return $id;
220 }

◆ createWikiPage()

ilObjWiki::createWikiPage ( string  $a_page_title,
int  $a_template_page = 0 
)

Create new wiki page.

Definition at line 758 of file class.ilObjWiki.php.

761 : ilWikiPage {
762 // check if template has to be used
763 if ($a_template_page === 0) {
764 if (!$this->getEmptyPageTemplate()) {
765 $wt = new ilWikiPageTemplate($this->getId());
766 $ts = $wt->getAllInfo(ilWikiPageTemplate::TYPE_NEW_PAGES);
767 if (count($ts) === 1) {
768 $t = current($ts);
769 $a_template_page = $t["wpage_id"];
770 }
771 }
772 }
773
774 // create the page
775 $page = new ilWikiPage();
776 $page->setWikiId($this->getId());
777 $page->setTitle(ilWikiUtil::makeDbTitle($a_page_title));
778 if ($this->getRating() && $this->getRatingForNewPages()) {
779 $page->setRating(true);
780 }
781
782 // needed for notification
783 $page->setWikiRefId($this->getRefId());
784 $page->create();
785
786 // copy template into new page
787 if ($a_template_page > 0) {
788 $orig = new ilWikiPage($a_template_page);
789 $orig->copy($page->getId());
790
791 // #15718
793 0,
794 $this->getId(),
795 $this->getId(),
796 "wpg",
797 $a_template_page,
798 $page->getId()
799 );
800 }
801
802 return $page;
803 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
static makeDbTitle(string $a_par)

References ILIAS\Survey\Mode\getId(), and ilWikiPageTemplate\TYPE_NEW_PAGES.

+ Here is the call graph for this function:

◆ decorateAdvMDValue()

ilObjWiki::decorateAdvMDValue ( string  $a_value)

Decorate adv md value.

Parameters
string$a_valuevalue
Returns
string decorated value (includes HTML)

Definition at line 871 of file class.ilObjWiki.php.

871 : string
872 {
873 if (ilWikiPage::_wikiPageExists($this->getId(), $a_value)) {
874 $url = ilObjWikiGUI::getGotoLink($this->getRefId(), $a_value);
875 return "<a href='" . $url . "'>" . $a_value . "</a>";
876 }
877
878 return $a_value;
879 }
static getGotoLink(int $a_ref_id, string $a_page="")
static _wikiPageExists(int $a_wiki_id, string $a_title)
$url

References $url, ilWikiPage\_wikiPageExists(), ilObjWikiGUI\getGotoLink(), and ILIAS\Survey\Mode\getId().

+ Here is the call graph for this function:

◆ delete()

ilObjWiki::delete ( )

delete object and all related data

Reimplemented from ilObject.

Definition at line 291 of file class.ilObjWiki.php.

291 : bool
292 {
294
295 // always call parent delete function first!!
296 if (!parent::delete()) {
297 return false;
298 }
299
300 // delete record of table il_wiki_data
301 $query = "DELETE FROM il_wiki_data" .
302 " WHERE id = " . $ilDB->quote($this->getId(), "integer");
303 $ilDB->manipulate($query);
304
305 // remove all notifications
307
309
310 return true;
311 }
static removeForObject(int $type, int $id)
Remove all notifications for given object.
static deleteAllPagesOfWiki(int $a_wiki_id)

References $ilDB, $query, ilWikiPage\deleteAllPagesOfWiki(), ILIAS\Survey\Mode\getId(), ilNotification\removeForObject(), and ilNotification\TYPE_WIKI.

+ Here is the call graph for this function:

◆ deliverUserHTMLExport()

ilObjWiki::deliverUserHTMLExport ( bool  $with_comments = false)

Definition at line 855 of file class.ilObjWiki.php.

857 : void {
860
861 $user_export = new ilWikiUserHTMLExport($this, $ilDB, $ilUser, $with_comments);
862 $user_export->deliverFile();
863 }
ilObjUser $user
Class manages user html export.
$ilUser
Definition: imgupload.php:34

◆ fixImportantPagesNumbering()

ilObjWiki::fixImportantPagesNumbering ( )

Definition at line 587 of file class.ilObjWiki.php.

587 : void
588 {
590
591 $ipages = self::_lookupImportantPagesList($this->getId());
592
593 // fix indentation: no 2 is allowed after a 0
594 $c_indent = 0;
595 foreach ($ipages as $k => $v) {
596 if ($v["indent"] == 2 && $c_indent == 0) {
597 $ipages[$k]["indent"] = 1;
598 }
599 $c_indent = $ipages[$k]["indent"];
600 }
601
602 $ord = 10;
603 foreach ($ipages as $k => $v) {
604 $ilDB->manipulate(
605 $q = "UPDATE il_wiki_imp_pages SET " .
606 " ord = " . $ilDB->quote($ord, "integer") .
607 ", indent = " . $ilDB->quote($v["indent"], "integer") .
608 " WHERE wiki_id = " . $ilDB->quote($v["wiki_id"], "integer") .
609 " AND page_id = " . $ilDB->quote($v["page_id"], "integer")
610 );
611 $ord += 10;
612 }
613 }
static _lookupImportantPagesList(int $a_wiki_id)

References $ilDB, and ILIAS\Survey\Mode\getId().

+ Here is the call graph for this function:

◆ getAdvMDSubItemTitle()

static ilObjWiki::getAdvMDSubItemTitle ( int  $a_obj_id,
string  $a_sub_type,
int  $a_sub_id 
)
static

Implements ilAdvancedMetaDataSubItems.

Definition at line 805 of file class.ilObjWiki.php.

809 : string {
810 global $DIC;
811
812 $lng = $DIC->language();
813
814 if ($a_sub_type === "wpg") {
815 $lng->loadLanguageModule("wiki");
816 return $lng->txt("wiki_wpg") . ' "' . ilWikiPage::lookupTitle($a_sub_id) . '"';
817 }
818 return "";
819 }
loadLanguageModule(string $a_module)
Load language module.
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
ilLanguage $lng
static lookupTitle(int $a_page_id)

References $lng, and ilWikiPage\lookupTitle().

+ Here is the call graph for this function:

◆ getEmptyPageTemplate()

ilObjWiki::getEmptyPageTemplate ( )

Definition at line 178 of file class.ilObjWiki.php.

178 : bool
179 {
181 }
bool $empty_page_templ

References $empty_page_templ.

◆ getIntroduction()

ilObjWiki::getIntroduction ( )

Definition at line 158 of file class.ilObjWiki.php.

158 : string
159 {
160 return $this->introduction;
161 }
string $introduction

References $introduction.

◆ getLinkMetadataValues()

ilObjWiki::getLinkMetadataValues ( )

Definition at line 188 of file class.ilObjWiki.php.

188 : bool
189 {
191 }
bool $link_md_values

References $link_md_values.

◆ getOnline()

ilObjWiki::getOnline ( )

Definition at line 66 of file class.ilObjWiki.php.

66 : bool
67 {
68 return $this->online;
69 }

References $online.

◆ getPageToc()

ilObjWiki::getPageToc ( )

Definition at line 168 of file class.ilObjWiki.php.

168 : bool
169 {
170 return $this->page_toc;
171 }

References $page_toc.

◆ getPublicNotes()

ilObjWiki::getPublicNotes ( )

Definition at line 128 of file class.ilObjWiki.php.

128 : bool
129 {
130 return $this->public_notes;
131 }
bool $public_notes

References $public_notes.

◆ getRating()

ilObjWiki::getRating ( )

Definition at line 88 of file class.ilObjWiki.php.

88 : bool
89 {
90 return $this->rating;
91 }

References $rating.

◆ getRatingAsBlock()

ilObjWiki::getRatingAsBlock ( )

Definition at line 98 of file class.ilObjWiki.php.

98 : bool
99 {
100 return $this->rating_block;
101 }
bool $rating_block

References $rating_block.

◆ getRatingCategories()

ilObjWiki::getRatingCategories ( )

Definition at line 118 of file class.ilObjWiki.php.

118 : bool
119 {
121 }
bool $rating_categories

References $rating_categories.

◆ getRatingForNewPages()

ilObjWiki::getRatingForNewPages ( )

Definition at line 108 of file class.ilObjWiki.php.

108 : bool
109 {
111 }
bool $rating_new_pages

References $rating_new_pages.

◆ getRatingOverall()

ilObjWiki::getRatingOverall ( )

Definition at line 77 of file class.ilObjWiki.php.

77 : bool
78 {
80 }
bool $rating_overall

References $rating_overall.

◆ getShortTitle()

ilObjWiki::getShortTitle ( )

Definition at line 148 of file class.ilObjWiki.php.

148 : string
149 {
150 return $this->shorttitle;
151 }
string $shorttitle

References $shorttitle.

◆ getStartPage()

ilObjWiki::getStartPage ( )

Definition at line 138 of file class.ilObjWiki.php.

138 : string
139 {
140 return $this->startpage;
141 }
string $startpage

References $startpage.

◆ getTemplateSelectionOnCreation()

ilObjWiki::getTemplateSelectionOnCreation ( )

Get template selection on creation? If more than one template (including empty page template) is activated -> return true.

Returns
bool true, if manual template selection needed

Definition at line 743 of file class.ilObjWiki.php.

743 : bool
744 {
745 $num = (int) $this->getEmptyPageTemplate();
746 $wt = new ilWikiPageTemplate($this->getId());
747 $ts = $wt->getAllInfo(ilWikiPageTemplate::TYPE_NEW_PAGES);
748 $num += count($ts);
749 if ($num > 1) {
750 return true;
751 }
752 return false;
753 }

References ILIAS\Survey\Mode\getId(), ILIAS\Repository\int(), and ilWikiPageTemplate\TYPE_NEW_PAGES.

+ Here is the call graph for this function:

◆ getUserHTMLExportProgress()

ilObjWiki::getUserHTMLExportProgress ( bool  $with_comments = false)

Get user html export progress.

Returns
array progress info

Definition at line 845 of file class.ilObjWiki.php.

847 : array {
850
851 $user_export = new ilWikiUserHTMLExport($this, $ilDB, $ilUser, $with_comments);
852 return $user_export->getProgress();
853 }

◆ initUserHTMLExport()

ilObjWiki::initUserHTMLExport ( bool  $with_comments = false)

Definition at line 821 of file class.ilObjWiki.php.

823 : void {
826
827 $user_export = new ilWikiUserHTMLExport($this, $ilDB, $ilUser, $with_comments);
828 $user_export->initUserHTMLExport();
829 }

◆ isCommentsExportPossible()

ilObjWiki::isCommentsExportPossible ( )

Is export possible.

Definition at line 884 of file class.ilObjWiki.php.

884 : bool
885 {
888 if ($setting->get("disable_comments")) {
889 return false;
890 }
891
892 if (!$this->getPublicNotes()) {
893 return false;
894 }
895 if (!$privacy->enabledCommentsExport()) {
896 return false;
897 }
898 return true;
899 }
ilSetting $setting
get(string $a_keyword, ?string $a_default_value=null)
get setting

References ilSetting\get(), and ilPrivacySettings\getInstance().

+ Here is the call graph for this function:

◆ isImportantPage()

ilObjWiki::isImportantPage ( int  $a_page_id)

Definition at line 512 of file class.ilObjWiki.php.

514 : bool {
516
517 $set = $ilDB->query(
518 "SELECT * FROM il_wiki_imp_pages WHERE " .
519 " wiki_id = " . $ilDB->quote($this->getId(), "integer") . " AND " .
520 " page_id = " . $ilDB->quote($a_page_id, "integer")
521 );
522 if ($ilDB->fetchAssoc($set)) {
523 return true;
524 }
525 return false;
526 }

◆ read()

ilObjWiki::read ( )

Reimplemented from ilObject.

Definition at line 261 of file class.ilObjWiki.php.

261 : void
262 {
264
265 parent::read();
266
267 $query = "SELECT * FROM il_wiki_data WHERE id = " .
268 $ilDB->quote($this->getId(), "integer");
269 $set = $ilDB->query($query);
270 $rec = $ilDB->fetchAssoc($set);
271
272 $this->setOnline((bool) $rec["is_online"]);
273 $this->setStartPage((string) $rec["startpage"]);
274 $this->setShortTitle((string) $rec["short"]);
275 $this->setRatingOverall((bool) $rec["rating_overall"]);
276 $this->setRating((bool) $rec["rating"]);
277 $this->setRatingAsBlock((bool) $rec["rating_side"]);
278 $this->setRatingForNewPages((bool) $rec["rating_new"]);
279 $this->setRatingCategories((bool) $rec["rating_ext"]);
280 $this->setPublicNotes((bool) $rec["public_notes"]);
281 $this->setIntroduction((string) $rec["introduction"]);
282 $this->setPageToc((bool) $rec["page_toc"]);
283 $this->setEmptyPageTemplate((bool) $rec["empty_page_templ"]);
284 $this->setLinkMetadataValues((bool) $rec["link_md_values"]);
285 }
setLinkMetadataValues(bool $a_val)
setRatingAsBlock(bool $a_rating)
setRating(bool $a_rating)
setPageToc(bool $a_val)
setOnline(bool $a_online)
setStartPage(string $a_startpage)
setIntroduction(string $a_introduction)
setEmptyPageTemplate(bool $a_val)
setRatingForNewPages(bool $a_rating)
setPublicNotes(bool $a_val)
setShortTitle(string $a_shorttitle)
setRatingOverall(bool $a_rating)
setRatingCategories(bool $a_rating)

References $ilDB, $query, and ILIAS\Survey\Mode\getId().

+ Here is the call graph for this function:

◆ removeImportantPage()

ilObjWiki::removeImportantPage ( int  $a_id)

Definition at line 528 of file class.ilObjWiki.php.

530 : void {
532
533 $ilDB->manipulate(
534 "DELETE FROM il_wiki_imp_pages WHERE "
535 . " wiki_id = " . $ilDB->quote($this->getId(), "integer")
536 . " AND page_id = " . $ilDB->quote($a_id, "integer")
537 );
538
540 }
fixImportantPagesNumbering()

◆ saveOrderingAndIndentation()

ilObjWiki::saveOrderingAndIndentation ( array  $a_ord,
array  $a_indent 
)

Definition at line 542 of file class.ilObjWiki.php.

545 : bool {
547
548 $ipages = self::_lookupImportantPagesList($this->getId());
549
550 foreach ($ipages as $k => $v) {
551 if (isset($a_ord[$v["page_id"]])) {
552 $ipages[$k]["ord"] = (int) $a_ord[$v["page_id"]];
553 }
554 if (isset($a_indent[$v["page_id"]])) {
555 $ipages[$k]["indent"] = (int) $a_indent[$v["page_id"]];
556 }
557 }
558 $ipages = ilArrayUtil::sortArray($ipages, "ord", "asc", true);
559
560 // fix indentation: no 2 is allowed after a 0
561 $c_indent = 0;
562 $fixed = false;
563 foreach ($ipages as $k => $v) {
564 if ($v["indent"] == 2 && $c_indent == 0) {
565 $ipages[$k]["indent"] = 1;
566 $fixed = true;
567 }
568 $c_indent = $ipages[$k]["indent"];
569 }
570
571 $ord = 10;
572 reset($ipages);
573 foreach ($ipages as $k => $v) {
574 $ilDB->manipulate(
575 $q = "UPDATE il_wiki_imp_pages SET " .
576 " ord = " . $ilDB->quote($ord, "integer") . "," .
577 " indent = " . $ilDB->quote($v["indent"], "integer") .
578 " WHERE wiki_id = " . $ilDB->quote($v["wiki_id"], "integer") .
579 " AND page_id = " . $ilDB->quote($v["page_id"], "integer")
580 );
581 $ord += 10;
582 }
583
584 return $fixed;
585 }
static sortArray(array $array, string $a_array_sortby_key, string $a_array_sortorder="asc", bool $a_numeric=false, bool $a_keep_keys=false)

◆ setEmptyPageTemplate()

ilObjWiki::setEmptyPageTemplate ( bool  $a_val)

Definition at line 173 of file class.ilObjWiki.php.

173 : void
174 {
175 $this->empty_page_templ = $a_val;
176 }

◆ setIntroduction()

ilObjWiki::setIntroduction ( string  $a_introduction)

Definition at line 153 of file class.ilObjWiki.php.

153 : void
154 {
155 $this->introduction = $a_introduction;
156 }

◆ setLinkMetadataValues()

ilObjWiki::setLinkMetadataValues ( bool  $a_val)

Definition at line 183 of file class.ilObjWiki.php.

183 : void
184 {
185 $this->link_md_values = $a_val;
186 }

◆ setOnline()

ilObjWiki::setOnline ( bool  $a_online)

Definition at line 61 of file class.ilObjWiki.php.

61 : void
62 {
63 $this->online = $a_online;
64 }

◆ setPageToc()

ilObjWiki::setPageToc ( bool  $a_val)

Definition at line 163 of file class.ilObjWiki.php.

163 : void
164 {
165 $this->page_toc = $a_val;
166 }

◆ setPublicNotes()

ilObjWiki::setPublicNotes ( bool  $a_val)

Definition at line 123 of file class.ilObjWiki.php.

123 : void
124 {
125 $this->public_notes = $a_val;
126 }

◆ setRating()

ilObjWiki::setRating ( bool  $a_rating)

Definition at line 83 of file class.ilObjWiki.php.

83 : void
84 {
85 $this->rating = $a_rating;
86 }

◆ setRatingAsBlock()

ilObjWiki::setRatingAsBlock ( bool  $a_rating)

Definition at line 93 of file class.ilObjWiki.php.

93 : void
94 {
95 $this->rating_block = $a_rating;
96 }

◆ setRatingCategories()

ilObjWiki::setRatingCategories ( bool  $a_rating)

Definition at line 113 of file class.ilObjWiki.php.

113 : void
114 {
115 $this->rating_categories = $a_rating;
116 }

◆ setRatingForNewPages()

ilObjWiki::setRatingForNewPages ( bool  $a_rating)

Definition at line 103 of file class.ilObjWiki.php.

103 : void
104 {
105 $this->rating_new_pages = $a_rating;
106 }

◆ setRatingOverall()

ilObjWiki::setRatingOverall ( bool  $a_rating)

Definition at line 72 of file class.ilObjWiki.php.

72 : void
73 {
74 $this->rating_overall = $a_rating;
75 }

◆ setShortTitle()

ilObjWiki::setShortTitle ( string  $a_shorttitle)

Definition at line 143 of file class.ilObjWiki.php.

143 : void
144 {
145 $this->shorttitle = $a_shorttitle;
146 }

◆ setStartPage()

ilObjWiki::setStartPage ( string  $a_startpage)

Definition at line 133 of file class.ilObjWiki.php.

133 : void
134 {
135 $this->startpage = ilWikiUtil::makeDbTitle($a_startpage);
136 }

References ilWikiUtil\makeDbTitle().

+ Here is the call graph for this function:

◆ startUserHTMLExport()

ilObjWiki::startUserHTMLExport ( bool  $with_comments = false)

Definition at line 831 of file class.ilObjWiki.php.

833 : void {
836
837 $user_export = new ilWikiUserHTMLExport($this, $ilDB, $ilUser, $with_comments);
838 $user_export->startUserHTMLExport();
839 }

◆ update()

ilObjWiki::update ( bool  $a_prevent_start_page_creation = false)

Definition at line 222 of file class.ilObjWiki.php.

224 : bool {
226
227 if (!parent::update()) {
228 return false;
229 }
230
231 $ilDB->update("il_wiki_data", array(
232 "is_online" => array("integer", $this->getOnline()),
233 "startpage" => array("text", $this->getStartPage()),
234 "short" => array("text", $this->getShortTitle()),
235 "rating_overall" => array("integer", $this->getRatingOverall()),
236 "rating" => array("integer", $this->getRating()),
237 "rating_side" => array("integer", $this->getRatingAsBlock()), // #13455
238 "rating_new" => array("integer", $this->getRatingForNewPages()),
239 "rating_ext" => array("integer", $this->getRatingCategories()),
240 "public_notes" => array("integer", $this->getPublicNotes()),
241 "introduction" => array("clob", $this->getIntroduction()),
242 "page_toc" => array("integer", $this->getPageToc()),
243 "link_md_values" => array("integer", $this->getLinkMetadataValues()),
244 "empty_page_templ" => array("integer", $this->getEmptyPageTemplate())
245 ), array(
246 "id" => array("integer", $this->getId())
247 ));
248
249 // check whether start page exists
250 if (!ilWikiPage::exists($this->getId(), $this->getStartPage())
251 && !$a_prevent_start_page_creation) {
252 $start_page = new ilWikiPage();
253 $start_page->setWikiId($this->getId());
254 $start_page->setTitle($this->getStartPage());
255 $start_page->create();
256 }
257
258 return true;
259 }
static exists(int $a_wiki_id, string $a_title)
Checks whether a page with given title exists.

◆ updateInternalLinksOnCopy()

ilObjWiki::updateInternalLinksOnCopy ( array  $map)
protected

Definition at line 718 of file class.ilObjWiki.php.

718 : void
719 {
720 foreach ($map as $old_page_id => $new_page_id) {
721 // get links with targets inside the wiki
723 "wpg:pg",
724 $old_page_id,
725 "-"
726 );
727 foreach ($targets as $t) {
728 if ((int) $t["inst"] === 0 && in_array($t["type"], ["wpag", "wpage"]) && isset($map[(int) $t["id"]])) {
729 $new_page = new ilWikiPage($new_page_id);
730 if ($new_page->moveIntLinks([$t["id"] => $map[(int) $t["id"]]])) {
731 $new_page->update(true, true);
732 }
733 }
734 }
735 }
736 }

References ilInternalLink\_getTargetsOfSource().

+ Here is the call graph for this function:

◆ writeStartPage()

static ilObjWiki::writeStartPage ( int  $a_id,
string  $a_name 
)
static

Definition at line 404 of file class.ilObjWiki.php.

404 : void
405 {
406 global $DIC;
407
408 $ilDB = $DIC->database();
409
410 $ilDB->manipulate(
411 "UPDATE il_wiki_data SET " .
412 " startpage = " . $ilDB->quote(ilWikiUtil::makeDbTitle($a_name), "text") .
413 " WHERE id = " . $ilDB->quote($a_id, "integer")
414 );
415 }

References $DIC, $ilDB, and ilWikiUtil\makeDbTitle().

+ Here is the call graph for this function:

Field Documentation

◆ $content_style_service

ILIAS Style Content DomainService ilObjWiki::$content_style_service
protected

Definition at line 42 of file class.ilObjWiki.php.

◆ $empty_page_templ

bool ilObjWiki::$empty_page_templ = true
protected

Definition at line 39 of file class.ilObjWiki.php.

Referenced by getEmptyPageTemplate().

◆ $introduction

string ilObjWiki::$introduction = ""
protected

Definition at line 28 of file class.ilObjWiki.php.

Referenced by getIntroduction().

◆ $link_md_values

bool ilObjWiki::$link_md_values = false
protected

Definition at line 40 of file class.ilObjWiki.php.

Referenced by getLinkMetadataValues().

◆ $online

bool ilObjWiki::$online = false
protected

Definition at line 37 of file class.ilObjWiki.php.

Referenced by getOnline().

◆ $page_toc

bool ilObjWiki::$page_toc = false
protected

Definition at line 26 of file class.ilObjWiki.php.

Referenced by getPageToc().

◆ $public_notes

bool ilObjWiki::$public_notes = true
protected

Definition at line 38 of file class.ilObjWiki.php.

Referenced by getPublicNotes().

◆ $rating

bool ilObjWiki::$rating = false
protected

Definition at line 33 of file class.ilObjWiki.php.

Referenced by getRating().

◆ $rating_block

bool ilObjWiki::$rating_block = false
protected

Definition at line 34 of file class.ilObjWiki.php.

Referenced by getRatingAsBlock().

◆ $rating_categories

bool ilObjWiki::$rating_categories = false
protected

Definition at line 31 of file class.ilObjWiki.php.

Referenced by getRatingCategories().

◆ $rating_new_pages

bool ilObjWiki::$rating_new_pages = false
protected

Definition at line 32 of file class.ilObjWiki.php.

Referenced by getRatingForNewPages().

◆ $rating_overall

bool ilObjWiki::$rating_overall = false
protected

Definition at line 35 of file class.ilObjWiki.php.

Referenced by getRatingOverall().

◆ $setting

ilSetting ilObjWiki::$setting
protected

Definition at line 41 of file class.ilObjWiki.php.

◆ $shorttitle

string ilObjWiki::$shorttitle = ""
protected

Definition at line 29 of file class.ilObjWiki.php.

Referenced by getShortTitle().

◆ $startpage

string ilObjWiki::$startpage = ""
protected

Definition at line 30 of file class.ilObjWiki.php.

Referenced by getStartPage().

◆ $style_id

int ilObjWiki::$style_id = 0
protected

Definition at line 27 of file class.ilObjWiki.php.

◆ $user

ilObjUser ilObjWiki::$user
protected

Definition at line 36 of file class.ilObjWiki.php.


The documentation for this class was generated from the following file: