1)src - project directory
2)mystie - main login stuffs
contain html files
- mysite
- home.html
- login.html
- register.html
- registration
- logged_out.html
src urls :
from django.contrib.auth import views as auth_views
will import the authentication stuff
for r'^login/' we used template name : 'mysite/login.html'
for r'^logout/' we used template name : 'registration/logged_out.html'
including mysite urls with
url(r'^',include('mysite.urls')
mysite urls :
for r'^$' it will call home.html
for r'^register' it will call register.html
from django import forms
username = forms.charField(required = true, max_length = 32, lable = "username")