function __construct($a_parent_type, $a_id = 0, $a_old_nr = 0, $a_slm_id = 0) { global $tpl, $ilCtrl; parent::__construct($a_parent_type, $a_id, $a_old_nr); //associated object include_once "./Services/Style/classes/class.ilPageLayout.php"; $this->layout_object = new ilPageLayout($a_id); $this->layout_object->readObject(); // content style include_once "./Services/Style/classes/class.ilObjStyleSheet.php"; $tpl->setCurrentBlock("ContentStyle"); $tpl->setVariable("LOCATION_CONTENT_STYLESHEET", ilObjStyleSheet::getContentStylePath($this->layout_object->getStyleId())); $tpl->parseCurrentBlock(); $tpl->setCurrentBlock("SyntaxStyle"); $tpl->setVariable("LOCATION_SYNTAX_STYLESHEET", ilObjStyleSheet::getSyntaxStylePath()); $tpl->setVariable("LOCATION_ADDITIONAL_STYLESHEET", ilObjStyleSheet::getPlaceHolderStylePath()); $tpl->parseCurrentBlock(); $this->setEnabledMaps(false); $this->setPreventHTMLUnmasking(false); $this->setEnabledInternalLinks(false); $this->setEnabledSelfAssessment(false); $this->setStyleId($this->layout_object->getStyleId()); //set For GUI and associated object $this->setLayoutMode(true); $this->obj->setLayoutMode(true); $this->slm_id = $a_slm_id; }
function showPage() { if (!$this->getPageObject()) { return; } switch ($this->getPageObject()->getType()) { case ilPortfolioTemplatePage::TYPE_BLOG_TEMPLATE: return $this->renderBlogTemplate(); default: // needed for placeholders include_once "Services/Style/classes/class.ilObjStyleSheet.php"; $this->tpl->addCss(ilObjStyleSheet::getPlaceHolderStylePath()); return parent::showPage(); } }
function __construct($a_parent_type, $a_id = 0, $a_old_nr = 0, $a_slm_id = 0) { global $tpl, $ilCtrl; parent::__construct($a_parent_type, $a_id, $a_old_nr); //associated object include_once "./Services/Style/classes/class.ilPageLayout.php"; $this->layout_object = new ilPageLayout($a_id); $this->layout_object->readObject(); // content style include_once "./Services/Style/classes/class.ilObjStyleSheet.php"; $tpl->setCurrentBlock("ContentStyle"); $tpl->setVariable("LOCATION_CONTENT_STYLESHEET", ilObjStyleSheet::getContentStylePath($this->layout_object->getStyleId())); $tpl->parseCurrentBlock(); $tpl->setCurrentBlock("SyntaxStyle"); $tpl->setVariable("LOCATION_SYNTAX_STYLESHEET", ilObjStyleSheet::getSyntaxStylePath()); $tpl->setVariable("LOCATION_ADDITIONAL_STYLESHEET", ilObjStyleSheet::getPlaceHolderStylePath()); $tpl->parseCurrentBlock(); $this->setStyleId($this->layout_object->getStyleId()); $this->slm_id = $a_slm_id; }
/** * Set content style sheet */ function setContentStyle() { global $tpl; // content styles include_once "./Services/Style/classes/class.ilObjStyleSheet.php"; $tpl->setCurrentBlock("ContentStyle"); $tpl->setVariable("LOCATION_CONTENT_STYLESHEET", ilObjStyleSheet::getContentStylePath($this->slm_object->getStyleSheetId())); $tpl->setVariable("LOCATION_ADDITIONAL_STYLESHEET", ilObjStyleSheet::getPlaceHolderStylePath()); $tpl->parseCurrentBlock(); $tpl->setCurrentBlock("SyntaxStyle"); $tpl->setVariable("LOCATION_SYNTAX_STYLESHEET", ilObjStyleSheet::getSyntaxStylePath()); $tpl->parseCurrentBlock(); }