Work in progress on project_required option (incomplete). Also started to integrate...
[timetracker.git] / WEB-INF / lib / form / TextArea.class.php
index 8a4e20a..5d48466 100644 (file)
 import('form.FormElement');
        
 class TextArea extends FormElement {
-    var $mPassword     = false;
     var $mColumns      = "";
     var $mRows         = "";
-    var $cClassName    = "TextArea";
     var $mOnKeyPress   = "";
 
-       function __construct($name,$value="")
-       {
-               $this->name = $name;
-               $this->value = $value;
-       }
-       
+  function __construct($name)
+  {
+    $this->class = 'TextArea';
+    $this->name = $name;
+  }
+
        function setColumns($value)     { $this->mColumns = $value;     }
        function getColumns()   { return $this->mColumns; }
 
        function setRows($value)        { $this->mRows = $value;        }
        function getRows()      { return $this->mRows; }
        
-       function toStringControl()      {
-               if (!$this->isRenderable()) return "";
-           
+       function getHtml() {
+    
            if ($this->id=="") $this->id = $this->mName;
            
            $js_maxlen = "";
@@ -70,8 +67,8 @@ class TextArea extends FormElement {
                        $html .= " maxlength=\"$this->max_length\"";
                }
 
-               if ($this->mStyle!="")
-                  $html .= " style=\"$this->mStyle\"";
+               if ($this->style!="")
+                  $html .= " style=\"$this->style\"";
 
                if ($this->mOnKeyPress) {
                        $html .= " onkeypress=\"$this->mOnKeyPress\"";