Try removing the IS_STRONG validator temporarily and see if it works. On Dec 12, 2:02 pm, Diz <[email protected]> wrote: > Hi All, > > I'm trying to use a custom user table AND an alternate login method. > I get everything to work (i.e. no errors) BUT when I try to log in I > get a flash message saying: > > "Minimum length is 8 > Must include at least 1 of the following : ~...@#$%^&*()_+-=?<>,.:;{}[]| > Must include at least 1 upper case" > > It appears that with a custom user auth table name web2py not using > the alternate login method. > > What am I doing wrong??? > > Key parts of the code are below (I've "x"ed out confidential data) and > in the sequence called. > > Thanks > > Diz > > auth_table = db.define_table('xxxx', > Field('first_name', length=128, default=''), > Field('last_name', length=128, default=''), > Field('email', length=128, default='', unique=True), > Field('password', 'password', length=256, readable=False, > label='Password'), > Field('registration_key', length=128, default= '', writable=False, > readable=False), > Field('email_work'), > Field('email_alternate'), > Field('phone_work'), > Field('phone_alternate'), > Field('phone_fax'), > Field('mailing_address','text')) > > auth_table.first_name.requires = IS_NOT_EMPTY > (error_message=auth.messages.is_empty) > auth_table.last_name.requires = IS_NOT_EMPTY > (error_message=auth.messages.is_empty) > auth_table.password.requires = [IS_STRONG(), CRYPT()] > auth_table.email.requires = [IS_EMAIL > (error_message=auth.messages.invalid_email), IS_NOT_IN_DB(db, > auth_table.email)] > > auth.settings.table_user = auth_table > auth.define_tables() > > auth.settings.actions_disabled.append('register') > auth.settings.login_methods = [ email_auth("smtp.xxxx.com:587", > "@xxxx.com")]
-- You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/web2py?hl=en.

