Added some tests
Removed redundant character set
Added helpful source url
Added closure and simplified code
Removed options for maxlength and autocomplete.
Added a bit of documentation