I am using a textarea
to emulate a piece of 9.5x11 Letter sized US paper.
I have a textarea
that is appropriately scaled to the 9.5x11 size; however, I want to prevent users from being able to add more text that would overflow the textarea
.
The goal is to limit the user to the boundaries of the textarea
, and thus preserve the ability to scale the content to Letter sized paper.
I've tried using resize:none
, and each option for overflow
, but these mainly seem to deal with the pixel size of the textarea
, and not the content inside it. How can I use Javascript, CSS, or HTML to keep the user within the boundaries of the textarea
?