/** * Constructor * * @param string $type text, url, number, email, image, submit, date, search, etc. */ public function __construct($type) { parent::__construct('input'); $this->setAttribute('type', $type); }
/** * Constructor */ public function __construct($method = 'post') { parent::__construct('form'); $this->setAttribute('method', $method); }
/** * Constructor */ public function __construct($type = 'submit') { parent::__construct('button'); $this->setAttribute('type', $type); }
public function __construct() { parent::__construct('select'); }
public function __construct() { parent::__construct('textarea'); }