<?phpfunction password($pass) { if (preg_match("#^[a-zа-яё0-9-_ ]{6,32}$#ui", $pass)) { return true; }}