<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Field; use ModStart\Core\Util\HtmlUtil; class RichHtml extends AbstractField { protected $listable = false; protected static $js = array('asset/common/editor.js'); protected function setup() { $this->addVariables(array('editorMode' => 'default', 'server' => modstart_admin_url('data/ueditor'), 'htmlFilter' => true, 'editorOption' => null)); } public function editorMode($lZlEV) { $this->addVariables(array('editorMode' => $lZlEV)); return $this; } public function htmlFilter($geg6A = true) { $this->addVariables(array('htmlFilter' => $geg6A)); return $this; } public function editorOption($mdHu1 = true) { $this->addVariables(array('editorOption' => $mdHu1)); return $this; } public function server($GBwzV) { $this->addVariables(array('server' => $GBwzV)); return $this; } public function prepareInput($mdHu1, $RpY_9) { if ($this->variables['htmlFilter']) { $mdHu1 = HtmlUtil::filter($mdHu1); } return $mdHu1; } }