jQuery.fn.watermark = function() {
  return this.each(function() {
	  var mark = this.title;
	  if (!mark) {
		  return;
	  }
	  var target = this;
	  if (!target.value || mark == this.value) {
		  $(target).addClass("watermark");
	  }
	  $(target).focus(function() {
		  if (this.value == mark && $(this).hasClass('watermark')) {
			  this.value = '';
			  $(this).removeClass("watermark");
		  }
	  });
	  $(this).blur(function() {
		  if (!this.value.length) {
			  this.value = mark;
			  $(this).addClass("watermark")
		  }
	  });
  });
};
