/**
  * Creates a TextBox
  *
  * @param string $s_id
  * @param string $s_value
  * @param bool $page_valid
  * @return TextBox
  */
 function TextBox($s_id, $s_value = '', $page_valid = null)
 {
     # set options assuming <input type="text" />
     parent::XhtmlElement("input");
     $this->SetMode(TextBoxMode::SingleLine());
     $this->SetXhtmlId($s_id);
     if ($page_valid === false and isset($_POST[$this->GetXhtmlId()])) {
         $this->SetText($_POST[$this->GetXhtmlId()]);
     } else {
         $this->SetText($s_value);
     }
 }