(function($){
 $.fn.magictf = function(options) {
  var defaults = {
   watermarkCSS: 'tf-watermark',
   defaultString: 'please enter some text'
  };
  var options = $.extend(defaults, options);
    
  return this.each(function() {
    obj = $(this);
    if(obj.val()=='') {
        obj.addClass(options.watermarkCSS).val(options.defaultString);
    }
    obj.focus(function(){
		cv = $(this).val();
		df = options.defaultString;
        if(cv==df){
            $(this).val('').removeClass(options.watermarkCSS);
        }
    });
    
    obj.blur(function(){
        if($(this).val()=='')
        {
            $(this).addClass(options.watermarkCSS).val(options.defaultString);
        }
    });
  });
 };
})(jQuery);
