You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
886 B
PHP
42 lines
886 B
PHP
<?php
|
|
|
|
namespace Artmark\Forms\Fields;
|
|
|
|
use Artmark\Forms\AbstractVisibleField;
|
|
|
|
/**
|
|
* Description of TextField
|
|
*
|
|
* @author Andrey Pokidov <pokidov@e-traffic.ru>
|
|
*/
|
|
class TextAreaField extends AbstractVisibleField
|
|
{
|
|
private $value = '';
|
|
|
|
public function __construct($form, $name, $value = '')
|
|
{
|
|
parent::__construct($form, 'textarea', $name);
|
|
|
|
$this->setValue($value);
|
|
}
|
|
|
|
/**
|
|
* Возвращает ранее заданное значение поля
|
|
* @return string
|
|
*/
|
|
public function value()
|
|
{
|
|
return $this->value;
|
|
}
|
|
|
|
/**
|
|
* Устанавливает новое значение для поля
|
|
* @param mixed $newValue новое значение
|
|
* @return $this
|
|
*/
|
|
public function setValue($newValue)
|
|
{
|
|
$this->value = strval($newValue);
|
|
}
|
|
}
|