(function($){
    $.fn.lurk =  function(value, options){
		
		var opts = $.extend({
			submitRemove : true
		}, options);
		
		this.each(function(){
			var $$ = $(this);

			function add() {
				if($$.val().length == 0) {
					$$.val(value).addClass("lurk");
				}
			}

			function remove() {
				if($$.val() == value) {
					$$.val('').removeClass("lurk");
				}
			}

			$$.mouseup(remove).focus(remove).blur(add);
			add();

			$$.parents("form").submit(function() {
				if (opts.submitRemove) {
					remove();
				}
				return true;
			});
		});
	}
})(jQuery);


