Skip to main content

Posts

Showing posts with the label maxlength

HTML <textarea> maxlength problem

We can limit the maximum characters in <input> with <maxlength> attribute. However it is not possible to do the same thing with <textarea> . This will be a problem if value of the <textarea> will be stored into database table and the length of the user input exceeds the field's length, either the value will be truncated or your database will throw an error to you.