When I do:
$email = new Text( 'email' );
$email->setAttribute( 'type', 'email' );
$this->add($email);
It gets rendered as:
<input type="text" id="email" name="email" />
Even though I explicitly set the type
attribute to "email". Is there a way to accomplish this without writing my own element class?