Update views.py

This is a new version of our view function login which validates and saves form's data.