Free course recommendation: Master JavaScript animation with GSAP through 34 free video lessons, step-by-step projects, and hands-on demos. Enroll now →
jMaxInput allows you to limit the input size of a textarea like it is done in Twitter. The number of characters left to type are shown while typing. The user can write as many characters as he wants (negative value is shown) but the text can only be submitted if the size of the input is below the limit (the button is active/inactive).
You can call it like this:
$("#div").maxinput();
You can as well define the following properties:
- limit: The maximum number of characters allowed
- position: The position of the message
- showtext: Boolean for showing the text message or just the number of characters left
- message: A custom message shown after the number of characters left
Tiny break: 📬 Want to stay up to date with frontend and trends in web design? Check out our Collective and stay in the loop.