Limit

Limit is a plugin for the javascript framework Jquery that limits the number of characters that can be entered in a textarea or input field. The plugin can also report the number of characters left before the user reaches the length limit.

How to use Limit

To use the full power of Limit you need two html elements; one textarea or input field and an element to show amount of characters left.

  1. You have <span id="charsLeft"></span> chars left.
  2. <textarea id="myTextarea"></textarea>
  3. <script type="text/javascript">
  4.     $('#myTextarea').limit('140','#charsLeft');
  5. </script>

If you don’t want to show the amount of characters left you can do like this.

  1.     $('#myTextarea').limit('140');
Change log
VersionChanges
1.2Optimized timed function and fixed an issue with flickering text

707 days ago

Read one article about glass; read this one about Corning, Corning’s Gorilla Glass, Apple and the future. http://t.co/xakeeQzU (via @VirUZI)

708 days ago

I just bought CHTEMELE; a boardgame about HTML5 for 2 – 5 players. http://t.co/kbpQLivu

710 days ago

A normal male ejaculation is equivalent of 16 terabyte of information. http://t.co/tkLndAwg

712 days ago

We are 18, we have no work, we don’t study, we are Anonymous. -We know. http://t.co/NHPa7gjR

712 days ago

We are 18, we have no work, we don’t study, we are Anonymous. -We know. http://t.co/NHPa7gjR

713 days ago

Anonymous plan to DDoS the Central Bank of Sweden’s website, in the middle of the Swedish night, to hurt our economy. Have fun, Goodnight :)

713 days ago

Book trailer for Instant: The story of Polaroid [the Apple of the 60s]. http://t.co/y4srSGmP