<?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($DtzzY) { $this->addVariables(array('editorMode' => $DtzzY)); return $this; } public function htmlFilter($udDBo = true) { $this->addVariables(array('htmlFilter' => $udDBo)); return $this; } public function editorOption($wvO30 = true) { $this->addVariables(array('editorOption' => $wvO30)); return $this; } public function server($GyeYJ) { $this->addVariables(array('server' => $GyeYJ)); return $this; } public function prepareInput($wvO30, $T92oK) { if ($this->variables['htmlFilter']) { $wvO30 = HtmlUtil::filter($wvO30); } return $wvO30; } }