(function(jQuery) {
  jQuery.fn.textboxhelp = function(options){
    var defaults = {help: 'Help me!', focuscls:'focus'};
    // merge defaults with coming parameters
    var opts = jQuery.extend(defaults, options);
    jQuery(this).val(opts.help);
    jQuery(this).focus(function(){
      // keep the text for check
      var t = jQuery(this).val();
      // when user focus to textbox, we should clean inside it
      // but first we should check exist text
      if(t.length > 0 && t == opts.help)
        jQuery(this).addClass(opts.focuscls).val('');
    }).blur(function() { 
      // keep the text for later check
      var t = jQuery(this).val();
      // if textbox is empty, we will add help text inside it again
      if('' == t)
         jQuery(this).removeClass(opts.focuscls).val(opts.help);
    });
  }
})(jQuery); 
