I have the following user function:
def user():
form=auth()
if request.args(0)=='login':
form.element(_type='submit').update(_value='Login')
session.alert='alert-success'
if request.args(0)=='logout':
session.alert='alert-success'
if request.args(0)=='not_authorized':
session.logged_out_message='Insufficient privileges, you are logged
out'
session.alert='alert-error'
redirect(URL('cms','index'))
return dict(form=form)
The problem is that when the user enter an invalid username/password
combination the invalid login flash has a 'alert-success'
Is there a way to set session.alert='alert-error' in this case?
Kind regards,
Annet
--