validating mandatory fields

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • pradeepjain
    Contributor
    • Jul 2007
    • 563

    validating mandatory fields

    Hii ,
    I have a form which has 20-30 textboxes which are mandatory ! is there a way of validating mandatory fields in easier ways by using a single function or some thing like tht ! bcos i will need to check each 20-30 text boxes if value is there or not !! Is there a way to do like define a class=mandatory and when it is found use function on it !
  • Dormilich
    Recognized Expert Expert
    • Aug 2008
    • 8694

    #2
    you can use a class when validating with javascript, but you don’t have that info in PHP. you have to somehow tell PHP the names of the mandatory fields, but then you can call the function.

    Comment

    Working...