Added support for text input (not text area)