Sunday, June 29, 2014

Re: django user authenication form in modal form twitter bootstrap

The issue is almost resolved. The only problem now I am facing is when I include login function which provides form with csrf token. The bootstrap modal forms dissappear immediately after is comes on screen. If I do not include this url using data-remote option the modal comes. But without csrf it do not let me login. 

Here is code 
********************************************************************************************************************
@csrf_protect
def login(request):
    return render_to_response('login.html',{},RequestContext(request))
********************************************************************************************************************
<div class="modal" id="myModal" data-remote="/accounts/login/" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">

Now the code in red is issue. when I include the the modal does not stay. 

Regards,
Sarfaraz Ahmed


--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/12cf734e-7204-475c-a65f-a88d2fe08a17%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment