Welcome, Guest
  • Author Topic: validating form through regular expressions?  (Read 2530 times)

    saumya

    • Senior Programmer
    • ****
    • Posts: 496
      • View Profile
      • currently active
      • Email
    Hi,
    I have a form in my html page.When i send the form i have a check and then if all the checks are ok then the form gets submitted.But the problem is that i have stucked at a place where my input textfiled has to be checked for alphabatic characters.How can I check that??If the text field contains alphabatic and only alphabatic characters then the form should be submitted or the script should go ahead.I need to check the alphabatics.

    Jorge Solis

    • Global Moderator
    • Systems Administrator
    • *****
    • Posts: 14616
      • View Profile
    Re: validating form through regular expressions?
    « Reply #1 on: 01/04/06, 11:38 »
    JavaScript have Regexp class, and you can check for not having numbers (0123456789) Don't remember how it works, but any JavaScript manual should document it.

    Jorge

    saumya

    • Senior Programmer
    • ****
    • Posts: 496
      • View Profile
      • currently active
      • Email
    Re: validating form through regular expressions?
    « Reply #2 on: 01/05/06, 00:47 »
    thanks jorge.I got the idea.