Jump to:

2011 Posts in 1436 Topics by 620 members

Form Questions

SilverStripe Forums » Form Questions » Validator in form ignores password

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 749 Views
  • _Vince
    Avatar
    Community Member
    161 Posts

    Validator in form ignores password Link to this post

    Hi, I have a custom form on a webpage, and some fields need to be filled in.

    I create the fields, I add them to the fieldset, I add the field names to a RequiredFields, as in

    $validator = new RequiredFields('Surname', 'FirstName', 'BBOUserName', 'Password', 'Email');

    And if I don't fill in the fields, I get an error message. Fine.

    Except that the RequiredFields is taking no notice of the Password field, which is defined as

    $Password = new ConfirmedPasswordField(
    $name = 'Password',
    $title = 'Password*',
    $value = $PasswordVal,
    $maxLength=8,
    false,
    'Please confirm your password'
    );

    What am I doing wrong?

  • _Vince
    Avatar
    Community Member
    161 Posts

    Re: Validator in form ignores password Link to this post

    *bounce*

  • _Vince
    Avatar
    Community Member
    161 Posts

    Re: Validator in form ignores password Link to this post

    Any idea of what I am doing wrong or how I can fix the problem?

    749 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.