/ Published in: jQuery
Expand |
Embed | Plain Text
jQuery('input, textarea').each(function() { var defaultval = this.value; jQuery(this).focus(function() { if(this.value == defaultval) { this.value = ''; } }); jQuery(this).blur(function() { if(this.value == '') { this.value = defaultval; } }); });
You need to login to post a comment.
