Return to Snippet

Revision: 56941
at April 26, 2012 03:42 by silent_killer


Initial Code
$(function(){
	$('input:text, textarea').each(function(){
		var txtval = $(this).val();
		$(this).focus(function(){
			$(this).val('')
		});
		$(this).blur(function(){
			if($(this).val() == ""){
				$(this).val(txtval);
			}
		});
	});
});

Initial URL

                                

Initial Description
autoclear input text and text area

Initial Title
input text box and text area auto clear

Initial Tags
jquery

Initial Language
jQuery