yardleybates
12-10-2003, 10:02 AM
Is there a way to set a max length on a textarea form object? I don't find that property as an option.
|
Click to See Complete Forum and Search --> : Textarea Form Object yardleybates 12-10-2003, 10:02 AM Is there a way to set a max length on a textarea form object? I don't find that property as an option. PeOfEo 12-10-2003, 10:33 PM Not like a regular text box no, but you can use a validater so that when a user clicks submit it says woops you crap is too long, sort of like with this forum, its really visible when you send a pm. Would you be interested in something like that? You can't just crap the ammount of text that can go into a text area feild though like you can with an input yardleybates 12-11-2003, 08:02 AM OK so what is the javascript function to get the length of the form field. I can find the property to retrieve the value, but not the length of the value. PeOfEo 12-11-2003, 05:36 PM dont know the java script string function for sure, in java it is feild.length() so try that. In vbscript it would be len feild, and you could use the mid statement to cap it without prompting the user, you know just cut it off at a certain number of characters, they would keep typeing but everything after that point would be lost. webdeveloper.com
Copyright Internet.com Inc., All Rights Reserved. |