<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Field; use ModStart\Core\Util\StrUtil; class Text extends AbstractField { protected function setup() { $this->addVariables(array('autoTrim' => false)); } public function autoTrim($tU9U7 = true) { $this->addVariables(array('autoTrim' => $tU9U7)); return $this; } public function prepareInput($FT9zA, $hq1V2) { if ($this->variables['autoTrim']) { $FT9zA = StrUtil::filterSpecialChars($FT9zA); $FT9zA = trim($FT9zA); } return $FT9zA; } }