text: !function(a){a.fn.textareaCount=function(b,c){function d(a){var b,c=0;for(b=0;b<a.length;b++)"\n"===a.charAt(b)&&c++;return c}function e(){var a=b.displayFormat;return a=a.replace("#input",p),a=a.replace("#words",s),q>0&&(a=a.replace("#max",q),a=a.replace("#left",r)),a}function f(){var a={input:p,max:q,left:r,words:s};return a}function g(a){return a.next(".charleft")}function h(){var a=navigator.appVersion;return-1!==a.toLowerCase().indexOf("win")}function i(a){var b=a+" ",c=/^[^A-Za-z0-9]+/gi,d=b.replace(c,""),e=/[^A-Za-z0-9]+/gi,f=d.replace(e," "),g=f.split(" ");return g}function j(a){var b=a.length-1;return b}function k(){var a,c,f,g=o.val(),k="function"==typeof b.charCounter?b.charCounter:t[b.charCounter],l=k(g);return b.maxCharacterSize>0?(b.truncate&&l>=b.maxCharacterSize&&(g=g.substring(0,b.maxCharacterSize)),a=d(g),c=b.maxCharacterSize,h()&&(c=b.maxCharacterSize-a),b.truncate&&l>c&&(f=this.scrollTop,o.val(g.substring(0,c)),this.scrollTop=f),m.removeClass(b.warningStyle+" "+b.errorStyle),c-l<=b.warningNumber&&m.addClass(b.warningStyle),0>c-l&&m.addClass(b.errorStyle),p=l,h()&&(p=l+a),s=j(i(o.val())),r=q-p):(a=d(g),p=l,h()&&(p=l+a),s=j(i(o.val()))),e()}function l(){return m.html(k()),"undefined"!=typeof c&&c.call(this,f()),!0}var m,n={maxCharacterSize:-1,truncate:!0,charCounter:"standard",originalStyle:"originalTextareaInfo",warningStyle:"warningTextareaInfo",errorStyle:"errorTextareaInfo",warningNumber:20,displayFormat:"#input characters | #words words"},o=a(this),p=0,q=b.maxCharacterSize,r=0,s=0,t={};t.standard=function(a){return a.length},t.twitter=function(a){var b=22,c=Array(b+1).join("*"),d="(https?://)?([a-z0-9+!*(),;?&=$_.-]+(:[a-z0-9+!*(),;?&=$_.-]+)?@)?([a-z0-9-.]*)\\.(travel|museum|[a-z]{2,4})(:[0-9]{2,5})?(/([a-z0-9+$_-]\\.?)+)*/?(\\?[a-z+&$_.-][a-z0-9;:@&%=+/$_.-]*)?(#[a-z_.-][a-z0-9+$_.-]*)?",e=new RegExp(d,"gi");return a.replace(e,c).length},b=a.extend(n,b),a("<div class='charleft'>&nbsp;</div>").insertAfter(o),m=g(o),m.addClass(b.originalStyle),o.bind("keyup",function(){l()}).bind("mouseover paste",function(){setTimeout(function(){l()},10)})}}(jQuery);