ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
ilForumExportGUI Class Reference

Forum export to HTML and Print. More...

+ Collaboration diagram for ilForumExportGUI:

Public Member Functions

 __construct ()
 
 ensureThreadBelongsToForum ($objId, \ilForumTopic $thread)
 
 executeCommand ()
 

Data Fields

const MODE_EXPORT_WEB = 1
 
const MODE_EXPORT_CLIENT = 2
 
 $ctrl
 
 $lng
 
 $access
 
 $error
 

Protected Member Functions

 prepare ()
 Prepare the export (init MathJax rendering) More...
 

Protected Attributes

 $is_moderator = false
 
 $frm
 

Detailed Description

Forum export to HTML and Print.

Author
Wolfgang Merkens wmerk.nosp@m.ens@.nosp@m.datab.nosp@m.ay.d.nosp@m.e
Version
$Id$

Definition at line 17 of file class.ilForumExportGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilForumExportGUI::__construct ( )

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

References $_GET, $ilCtrl, $ilErr, $lng, and ilForumProperties\getInstance().

41  {
42  global $lng, $ilCtrl, $ilAccess, $ilErr;
43 
44  $forum = new ilObjForum((int)$_GET['ref_id']);
45  $this->frm = $forum->Forum;
46  $this->objProperties = ilForumProperties::getInstance($forum->getId());
47 
48  $this->frm->setForumId($forum->getId());
49  $this->frm->setForumRefId($forum->getRefId());
50 
51  $this->ctrl = $ilCtrl;
52  $this->lng = $lng;
53  $this->access = $ilAccess;
54  $this->error = $ilErr;
55  $this->lng->loadLanguageModule('forum');
56 
57  $this->is_moderator = $this->access->checkAccess('moderate_frm', '', (int)$_GET['ref_id']);
58  }
global $ilErr
Definition: raiseError.php:16
$_GET["client_id"]
global $ilCtrl
Definition: ilias.php:18
static getInstance($a_obj_id=0)
Class ilObjForum.
+ Here is the call graph for this function:

Member Function Documentation

◆ ensureThreadBelongsToForum()

ilForumExportGUI::ensureThreadBelongsToForum (   $objId,
\ilForumTopic  $thread 
)
Parameters
int$objId
ilForumTopic$thread

Definition at line 64 of file class.ilForumExportGUI.php.

References ilForumTopic\getForumId(), and ilObjForum\lookupForumIdByObjId().

Referenced by executeCommand().

65  {
66  $forumId = \ilObjForum::lookupForumIdByObjId($objId);
67  if ((int)$thread->getForumId() !== (int)$forumId) {
68  $this->error->raiseError($this->lng->txt('permission_denied'), $this->error->MESSAGE);
69  }
70  }
static lookupForumIdByObjId($obj_id)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ executeCommand()

◆ prepare()

ilForumExportGUI::prepare ( )
protected

Prepare the export (init MathJax rendering)

Definition at line 483 of file class.ilForumExportGUI.php.

References ilMathJax\getInstance(), and ilMathJax\PURPOSE_EXPORT.

Referenced by executeCommand().

484  {
485  include_once './Services/MathJax/classes/class.ilMathJax.php';
488  ->setZoomFactor(10);
489  }
const PURPOSE_EXPORT
static getInstance()
Singleton: get instance.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ $access

ilForumExportGUI::$access

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

◆ $ctrl

ilForumExportGUI::$ctrl

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

◆ $error

ilForumExportGUI::$error

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

◆ $frm

ilForumExportGUI::$frm
protected

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

◆ $is_moderator

ilForumExportGUI::$is_moderator = false
protected

Definition at line 25 of file class.ilForumExportGUI.php.

Referenced by executeCommand().

◆ $lng

ilForumExportGUI::$lng

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

Referenced by __construct(), and executeCommand().

◆ MODE_EXPORT_CLIENT

const ilForumExportGUI::MODE_EXPORT_CLIENT = 2

Definition at line 20 of file class.ilForumExportGUI.php.

◆ MODE_EXPORT_WEB

const ilForumExportGUI::MODE_EXPORT_WEB = 1

Definition at line 19 of file class.ilForumExportGUI.php.


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