You are here

function _password_policy_constraint_js in Password Policy 6

Same name and namespace in other branches
  1. 7 password_policy.module \_password_policy_constraint_js()

Gets the javascript code from the constraint to be added to the password validation.

Parameters

$name: Name of the constraint.

$constraint: Constraint value.

$uid: User's id.

Return value

Javascript code snippet for the constraint.

1 call to _password_policy_constraint_js()
password_policy_add_policy_js in ./password_policy.module
Add password policy JS

File

./password_policy.module, line 845
The password policy module allows you to enforce a specific level of password complexity for the user passwords on the system.

Code

function _password_policy_constraint_js($name, $constraint, $uid) {
  _password_policy_constraints();
  if (function_exists('password_policy_constraint_' . $name . '_js')) {
    return call_user_func('password_policy_constraint_' . $name . '_js', $constraint, $uid);
  }
}