Version: v0.8.1 - Beta.  We welcome contributors & feedback.

Password.checkPattern

$password.checkPattern($regex) -> boolean

Description

Returns true if the plaintext password matches the given regex pattern.

$tryPassword = Input.get('password')

if !$tryPassword.checkPattern(rx'\d') {
    // need at least one digit
}