• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Tim Cooke
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Devaka Cooray
  • Ron McLeod
  • paul wheaton
Saloon Keepers:
  • Tim Moores
  • Piet Souris
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Frits Walraven
  • Scott Selikoff

javascript:charecter validation

 
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Friends,
I have a requirement in javascript.
I need to validate the TExtarea charecters.In Textarea only 7 lines shoud be
allow and total charecters length is 175 and the chrecter length per line
is 25 charecters.
Please provide me code for this.

requirement like this :
1) It should allow <=175 charecters
2) Each line should contain 25 charecters
3) important this is maximum lines are 7.
i implemented this but when i type the continuasly (onkey down) control
crossing the 7 lines.
if i copy and paste more than 7 lines allowing in this cast also.

thanks & Regards
chennarao

[Bear edit: removed 'urgent' from subject]
[ August 26, 2005: Message edited by: Bear Bibeault ]
 
Rancher
Posts: 43028
76
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
People here are not going to just write code for you. If you post what you have so far, and describe where you stuck, folks will be glad to help you get to the finish line.
 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You can try an approach of having 7 input type="text" fields one over another, so you can set maxlength on each.

It may not be pretty, but it's easier than trying to enforce your requirements on a textarea.
 
You can't have everything. Where would you put it?
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic