当前位置: 首页>>代码示例>>PHP>>正文


PHP ilTextAreaInputGUI::setPurifier方法代码示例

本文整理汇总了PHP中ilTextAreaInputGUI::setPurifier方法的典型用法代码示例。如果您正苦于以下问题:PHP ilTextAreaInputGUI::setPurifier方法的具体用法?PHP ilTextAreaInputGUI::setPurifier怎么用?PHP ilTextAreaInputGUI::setPurifier使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ilTextAreaInputGUI的用法示例。


在下文中一共展示了ilTextAreaInputGUI::setPurifier方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: StatutoryRegulationsObject

 public function StatutoryRegulationsObject()
 {
     $this->tpl->addBlockfile('ADM_CONTENT', 'adm_content', 'tpl.main_view.html', 'Services/Payment');
     $form = new ilPropertyFormGUI();
     $form->setFormAction($this->ctrl->getFormAction($this, 'saveStatutoryRegulations'));
     $form->setTitle($this->lng->txt('statutory_regulations'));
     $form->setTableWidth('100%');
     // message
     $post_gui = new ilTextAreaInputGUI($this->lng->txt('content'), 'statutory_regulations');
     $post_gui->setCols(50);
     $post_gui->setRows(15);
     $post_gui->setUseRte(true);
     $post_gui->addPlugin('latex');
     $post_gui->addButton('latex');
     $post_gui->addButton('pastelatex');
     $post_gui->addPlugin('ilimgupload');
     $post_gui->addButton('ilimgupload');
     $post_gui->removePlugin('advlink');
     $post_gui->removePlugin(ilRTE::ILIAS_IMG_MANAGER_PLUGIN);
     $post_gui->removePlugin('image');
     $post_gui->usePurifier(true);
     $post_gui->setRTERootBlockElement('');
     $post_gui->setRTESupport(ilObject::_lookupObjId($this->ref_id), 'pays~', 'frm_post', 'tpl.tinymce_frm_post.html', false, '3.4.7');
     $post_gui->disableButtons(array('charmap', 'undo', 'redo', 'justifyleft', 'justifycenter', 'justifyright', 'justifyfull', 'anchor', 'fullscreen', 'cut', 'copy', 'paste', 'pastetext', 'formatselect', 'image'));
     // purifier
     require_once 'Services/Html/classes/class.ilHtmlPurifierFactory.php';
     require_once 'Services/RTE/classes/class.ilRTE.php';
     $post_gui->setPurifier(ilHtmlPurifierFactory::_getInstanceByType('frm_post'));
     $post_gui->setValue(ilRTE::_replaceMediaObjectImageSrc($this->genSetData->get('statutory_regulations'), 1));
     $form->addItem($post_gui);
     // show staturaltyio regulations in shoppingcart
     $cb_showShoppingCart = new ilCheckboxInputGUI($this->lng->txt('show_sr_shoppingcart'), 'show_sr_shoppingcart');
     $cb_showShoppingCart->setInfo($this->lng->txt('show_sr_shoppingcart_info'));
     $cb_showShoppingCart->setValue(1);
     $cb_showShoppingCart->setChecked($this->genSetData->get('show_sr_shoppingcart'));
     $form->addItem($cb_showShoppingCart);
     // attach staturaltyio regulations at invoice
     $cb_attachInvoice = new ilCheckboxInputGUI($this->lng->txt('attach_sr_invoice'), 'attach_sr_invoice');
     $cb_attachInvoice->setInfo($this->lng->txt('attach_sr_invoice_info'));
     $cb_attachInvoice->setValue(1);
     $cb_attachInvoice->setChecked($this->genSetData->get('attach_sr_invoice'));
     $form->addItem($cb_attachInvoice);
     $form->addCommandButton('saveStatutoryRegulations', $this->lng->txt('save'));
     $this->tpl->setVariable('FORM', $form->getHTML());
 }
开发者ID:arlendotcn,项目名称:ilias,代码行数:45,代码来源:class.ilObjPaymentSettingsGUI.php

示例2: initTopicCreateForm

 private function initTopicCreateForm()
 {
     /**
      * @var $ilUser ilObjUser
      * @var $rbacsystem ilRbacSystem
      * @var $ilias ILIAS
      * @var $ilSetting ilSetting
      */
     global $ilUser, $rbacsystem, $ilias, $ilSetting;
     $this->create_topic_form_gui = new ilPropertyFormGUI();
     $this->create_topic_form_gui->setTitle($this->lng->txt('forums_new_thread'));
     $this->create_topic_form_gui->setTitleIcon(ilUtil::getImagePath('icon_frm.svg'));
     $this->create_topic_form_gui->setTableWidth('100%');
     // form action
     $this->create_topic_form_gui->setFormAction($this->ctrl->getFormAction($this, 'addThread'));
     if ($this->objProperties->isAnonymized() == 1) {
         $alias_gui = new ilTextInputGUI($this->lng->txt('forums_your_name'), 'alias');
         $alias_gui->setInfo($this->lng->txt('forums_use_alias'));
         $alias_gui->setMaxLength(255);
         $alias_gui->setSize(50);
         $this->create_topic_form_gui->addItem($alias_gui);
     } else {
         $alias_gui = new ilNonEditableValueGUI($this->lng->txt('forums_your_name'), 'alias');
         $alias_gui->setValue($ilUser->getLogin());
         $this->create_topic_form_gui->addItem($alias_gui);
     }
     // topic
     $subject_gui = new ilTextInputGUI($this->lng->txt('forums_thread'), 'subject');
     $subject_gui->setMaxLength(255);
     $subject_gui->setSize(50);
     $subject_gui->setRequired(true);
     $this->create_topic_form_gui->addItem($subject_gui);
     // message
     $post_gui = new ilTextAreaInputGUI($this->lng->txt('forums_the_post'), 'message');
     $post_gui->setCols(50);
     $post_gui->setRows(15);
     $post_gui->setRequired(true);
     $post_gui->setUseRte(true);
     $post_gui->addPlugin('latex');
     $post_gui->addButton('latex');
     $post_gui->addButton('pastelatex');
     $post_gui->addPlugin('ilfrmquote');
     //$post_gui->addPlugin('code');
     $post_gui->removePlugin('advlink');
     $post_gui->usePurifier(true);
     $post_gui->setRTERootBlockElement('');
     $post_gui->setRTESupport($ilUser->getId(), 'frm~', 'frm_post', 'tpl.tinymce_frm_post.html', false, '3.4.7');
     $post_gui->disableButtons(array('charmap', 'undo', 'redo', 'justifyleft', 'justifycenter', 'justifyright', 'justifyfull', 'anchor', 'fullscreen', 'cut', 'copy', 'paste', 'pastetext', 'formatselect'));
     // purifier
     require_once 'Services/Html/classes/class.ilHtmlPurifierFactory.php';
     $post_gui->setPurifier(ilHtmlPurifierFactory::_getInstanceByType('frm_post'));
     $this->create_topic_form_gui->addItem($post_gui);
     // file
     $fi = new ilFileWizardInputGUI($this->lng->txt('forums_attachments_add'), 'userfile');
     $fi->setFilenames(array(0 => ''));
     $this->create_topic_form_gui->addItem($fi);
     include_once 'Services/Mail/classes/class.ilMail.php';
     $umail = new ilMail($ilUser->getId());
     // catch hack attempts
     if ($rbacsystem->checkAccess('internal_mail', $umail->getMailObjectReferenceId()) && !$this->objProperties->isAnonymized()) {
         // direct notification
         $dir_notification_gui = new ilCheckboxInputGUI($this->lng->txt('forum_direct_notification'), 'notify');
         $dir_notification_gui->setInfo($this->lng->txt('forum_notify_me_directly'));
         $dir_notification_gui->setValue(1);
         $this->create_topic_form_gui->addItem($dir_notification_gui);
         if ($ilias->getSetting('forum_notification') != 0) {
             // gen. notification
             $gen_notification_gui = new ilCheckboxInputGUI($this->lng->txt('forum_general_notification'), 'notify_posts');
             $gen_notification_gui->setInfo($this->lng->txt('forum_notify_me_generally'));
             $gen_notification_gui->setValue(1);
             $this->create_topic_form_gui->addItem($gen_notification_gui);
         }
     }
     require_once 'Services/Captcha/classes/class.ilCaptchaUtil.php';
     if ($ilUser->isAnonymous() && !$ilUser->isCaptchaVerified() && ilCaptchaUtil::isActiveForForum()) {
         require_once 'Services/Captcha/classes/class.ilCaptchaInputGUI.php';
         $captcha = new ilCaptchaInputGUI($this->lng->txt('cont_captcha_code'), 'captcha_code');
         $captcha->setRequired(true);
         $this->create_topic_form_gui->addItem($captcha);
     }
     $this->create_topic_form_gui->addCommandButton('addThread', $this->lng->txt('create'));
     $this->create_topic_form_gui->addCommandButton('showThreads', $this->lng->txt('cancel'));
 }
开发者ID:bheyser,项目名称:qplskl,代码行数:83,代码来源:class.ilObjForumGUI.php


注:本文中的ilTextAreaInputGUI::setPurifier方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。