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

3 days ago

Wow! I don’t even remember anymore how I managed before this new awesome boilerstrap. http://t.co/bWzwqVf2

3 days ago

If you like coding and competing and want to see Stockholm at its best; Checkout Escape from /dev/null – DICE edition. http://t.co/0SapzZxz

5 days ago

Going where none has gone before and pushing the boundaries of what has been called done. Mine, @soe, @tussetor #SthlmStartupHack app ≈Done