5 include_once(
"Services/Block/classes/class.ilBlockGUI.php");
30 $this->
setTitle($lng->txt(
"my_bms"));
35 $this->
id = (empty(
$_GET[
"bmf_id"]))
81 $next_class = $ilCtrl->getNextClass();
82 $cmd = $ilCtrl->getCmd(
"getHTML");
108 include_once(
"./Services/Bookmarks/classes/class.ilBookmarkFolder.php");
110 $this->num_bookmarks = $bm_items[
"bookmarks"];
111 $this->num_folders = $bm_items[
"folders"];
114 ($this->num_bookmarks > 0 || $this->num_folders > 0))
116 if ($ilUser->getPref(
"il_pd_bkm_mode") ==
'tree')
122 $this->
setRowTemplate(
"tpl.bookmark_pd_list.html",
"Services/Bookmarks");
130 if ($this->num_bookmarks == 0 && $this->num_folders == 0)
145 include_once(
"./Services/Bookmarks/classes/class.ilBookmarkBlockExplorerGUI.php");
147 if (!$exp->handleCommand())
149 return "<div id='tree_div'>".$exp->getHTML().
"</div>";
162 $this->tpl->setVariable(
"FCOLSPAN", $this->
getColSpan());
163 if ($this->tpl->blockExists(
"block_footer"))
165 $this->tpl->setCurrentBlock(
"block_footer");
166 $this->tpl->parseCurrentBlock();
177 if ($this->num_bookmarks == 0 && $this->num_folders == 0)
184 $ilCtrl->getLinkTarget($this,
"setPdFlatMode"),
185 $ilCtrl->getLinkTarget($this,
"setPdFlatMode",
188 false,
false, ($ilUser->getPref(
"il_pd_bkm_mode") !=
'tree'));
192 $ilCtrl->getLinkTarget($this,
196 false,
false, ($ilUser->getPref(
"il_pd_bkm_mode") ==
'tree')
207 include_once(
"./Services/Bookmarks/classes/class.ilBookmarkFolder.php");
211 $sess_cur_bm_folder =
"";
214 $sess_cur_bm_folder =
$_SESSION[
"ilCurBMFolder"];
222 $ilCtrl->setParameter($this,
"curBMFolder",
227 "alt" => $lng->txt(
"bmf"),
229 "link" => $ilCtrl->getLinkTarget($this,
"setCurrentBookmarkFolder"));
234 foreach ($bm_items as $bm_item)
236 switch ($bm_item[
"type"])
239 $ilCtrl->setParameter($this,
"curBMFolder", $bm_item[
"obj_id"]);
242 "alt" => $lng->txt(
"bmf"),
245 "link" => $ilCtrl->getLinkTarget($this,
246 "setCurrentBookmarkFolder"),
253 "alt" => $lng->txt(
"bm"),
257 "target" =>
"_blank");
272 $this->tpl->setVariable(
"IMG_BM", $a_set[
"img"]);
273 $this->tpl->setVariable(
"IMG_ALT", $a_set[
"alt"]);
274 $this->tpl->setVariable(
"BM_TITLE", $a_set[
"title"]);
275 $this->tpl->setVariable(
"BM_LINK", $a_set[
"link"]);
295 return '<div class="small">'.$this->num_bookmarks.
" ".$lng->txt(
"bm_num_bookmarks").
", ".
296 $this->num_folders.
" ".$lng->txt(
"bm_num_bookmark_folders").
"</div>";
306 $ilUser->writePref(
"il_pd_bkm_mode",
'flat');
307 if ($ilCtrl->isAsynch())
314 $ilCtrl->redirectByClass(
"ilpersonaldesktopgui",
"show");
325 $ilUser->writePref(
"il_pd_bkm_mode",
'tree');
326 if ($ilCtrl->isAsynch())
333 $ilCtrl->redirectByClass(
"ilpersonaldesktopgui",
"show");
345 $ilCtrl->redirectByClass(
"ilpersonaldesktopgui",
"show");