Пример #1
0
 /**
  * Helper function to create a Hidden field.  Useful for quick adding it to a ComponentCollection
  *
  * @param string $name The field's HTML name attribute.
  * @param string $value A value to initialize this field with.
  * @param string $id The unique id of this component (defaults to an auto-assigned id).
  * @return PhpExt_Form_Hidden
  */
 public static function createHidden($name, $value = null, $id = null)
 {
     $c = new PhpExt_Form_Hidden();
     $c->setName($name);
     if ($value !== null) {
         $c->setValue($value);
     }
     if ($id !== null) {
         $c->setId($id);
     }
     return $c;
 }