Skip to content
jQuery plugin adding a clear button in text input fields http://plugins.jquery.com/project/clearable_text_field
Find file
Pull request Compare This branch is even with ono:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
example
.gitignore
README.textile
RELEASE_NOTE.textile
clear_cross.png
compressor_command_note.txt
jquery.clearableTextField.css
jquery.clearableTextField.js
jquery.clearableTextField.min.js

README.textile

Clearable Text Field is a jQuery plugin which shows up a cross icon to clear value when user input something in a form field.
Seeing example is the fastest way to understand. Example

FAQ

Selector examples

// All text fields
$('input[type=text]').clearableTextField();

// All text fields in search form
$('div.search input[type=text]').clearableTextField();

// All text fields but foo class
$('input:not(.foo)[type=text]').clearableTextField();

Can I change the cross image and the style?

Yes, you can do with editing or replacing jquery.clearableTextField.css.

Browser compatibility

I’ve tested with:

  • Safari4, FF3.5 on OS X
  • IE6, IE7, IE8, FF3.5 on win XP

jQuery version

I’ve tested with 1.3 and 1.4

Download

Just git clone or “download source” link above.

Contributors

Tatsuya Ono: me :)
Go Kameda: designed default icon.

Something went wrong with that request. Please try again.