Beispiel #1
0
def login(request):
    if request.method == 'POST':
        form = LoginForm(request.POST)
        if form.login(request):
            next = request.GET.get("next", "")
            if next:
                return redirect(next)
            return redirect('/')
    else:
        form = LoginForm()

    ctx = { 'form': form,  }
    return render(request, 'member/login.html', ctx)
Beispiel #2
0
def login(request):
    if request.method == 'POST':
        form = LoginForm(request.POST)
        if form.login(request):
            next = request.GET.get("next", "")
            if next:
                return redirect(next)
            return redirect('/')
    else:
        form = LoginForm()

    ctx = { 'form': form,  }
    return render_to_response('member/login.html', ctx, context_instance=RequestContext(request))
Beispiel #3
0
def login(request):
    if request.method == 'POST':
        form = LoginForm(request.POST)
        if form.login(request):
            next = request.GET.get("next", "")
            if next:
                return redirect(next)
            return redirect('/')
    else:
        form = LoginForm()

    ctx = { 'form': form,  }
    return render_to_response('member/login.html', ctx, context_instance=RequestContext(request))
Beispiel #4
0
def login(request):
    if request.method == 'POST':
        form = LoginForm(request.POST)
        if form.login(request):
            next = request.GET.get("next", "")
            if next:
                return redirect(next)
            return redirect('/')
    else:
        form = LoginForm()

    ctx = {
        'form': form,
    }
    return render(request, 'member/login.html', ctx)