Gentics Portal.Node PHP API
 All Classes Namespaces Functions Variables Pages
Public Member Functions | Public Attributes | List of all members
UserRecoveryForm Class Reference

Public Member Functions

 rules ()
 attributeLabels ()
 checkexists ($attribute, $params)

Public Attributes

 $login_or_email
 $user_id

Detailed Description

UserRecoveryForm class. UserRecoveryForm is the data structure for keeping user recovery form data. It is used by the 'recovery' action of 'UserController'.

Definition at line 8 of file UserRecoveryForm.php.

Member Function Documentation

UserRecoveryForm::attributeLabels ( )

Declares attribute labels.

Definition at line 29 of file UserRecoveryForm.php.

References UserModule\t().

{
return array(
'login_or_email'=>UserModule::t("Username or Email"),
);
}
UserRecoveryForm::rules ( )

Declares the validation rules. The rules state that username and password are required, and password needs to be authenticated.

Definition at line 16 of file UserRecoveryForm.php.

References UserModule\t().

{
return array(
// username and password are required
array('login_or_email', 'required'),
array('login_or_email', 'match', 'pattern' => '/^[A-Za-z0-9@.-\s,]+$/u','message' => UserModule::t("Incorrect symbols (A-z0-9).")),
// password needs to be authenticated
array('login_or_email', 'checkexists'),
);
}

The documentation for this class was generated from the following file: