Use jquery change event
Description: Bind an event handler to the "change" JavaScript event,
or trigger that event on an element.
An example
$("input[type='text']").change( function() {
// your code
});
The advantage that .change has over .keypress , .focus , .blur is that .change event will fire only when input has changed