
jQuery.fn.formtips=function(options){settings=jQuery.extend({tippedClass:"tipped"},options);return this.each(function(){jQuery(this).each(function(){var e=jQuery(this);jQuery(e).bind('focus',function(){var lv=jQuery(this).attr('title');if(jQuery(this).val()==lv){jQuery(this).val('').removeClass(settings.tippedClass);}
return false;});jQuery(e).bind('blur',function(){var lv=jQuery(this).attr('title');if(jQuery(this).val()==''){jQuery(this).val(lv).addClass(settings.tippedClass);}
return false;});var lv=jQuery(e).attr('title');if(jQuery(e).val()==''||jQuery(e).val()==jQuery(this).attr('title')){jQuery(e).val(lv).addClass(settings.tippedClass);}else{jQuery(e).removeClass(settings.tippedClass);}});if(jQuery('.'+settings.tippedClass,this).length>0){jQuery(this).submit(function(){jQuery('.'+settings.tippedClass,this).each(function(){var e=jQuery(this);var lv=jQuery(this).attr('title');if(jQuery(e).val()==lv){jQuery(e).val('').removeClass(settings.tippedClass);}});return true;});}});};
